main.cpp

# main.cpp - Name Aditya D Pharande STD SE Roll NO A-22...

• No School
• AA 1
• 1

This preview shows page 1 out of 1 page.

/* Name : Aditya D. Pharande STD : SE. Roll NO. : A-22. */ // CODE #include<iostream> #include<stdio.h> #include<graphics.h> #include<stdlib.h> using namespace std; #define SIN 0.86602540 void koch(int x1,int y1,int x2,int y2,int m) { int xx,yy,x[5],y[5],lx,ly,offx=50,offy=300; lx=(x2-x1)/3; ly=(y2-y1)/3; x[0]=x1; y[0]=y1; x[4]=x2; y[4]=y2; x[1]=x[0]+lx; y[1]=y[0]+ly; x[3]=x[0]+2*lx; y[3]=y[0]+2*ly; xx=x[3]-x[1]; yy=y[3]-y[1]; x[2]=xx*(0.5)+yy*(SIN); y[2]=-xx*(SIN)+yy*(0.5); x[2]=x[2]+x[1]; y[2]=y[2]+y[1]; if(m>0) { koch(x[0],y[0],x[1],y[1],m-1);
• Fall '19
• Return statement, Void type, int y1, Koch, void koch

{[ snackBarMessage ]}

### What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern