Skip to content

Commit cc1303e

Browse files
Create array_for
1 parent 6baef5c commit cc1303e

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

array_for

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
#include <iostream>
2+
using namespace std;
3+
4+
int main() {
5+
struct PunktT
6+
{
7+
double x;
8+
double y;
9+
};
10+
PunktT punkte[11];
11+
double m = 2.5;
12+
double b = -1;
13+
for (int i = 0; i < 11; i++) {
14+
double x = i-5; punkte[i].x = x;
15+
punkte[i].y = m*x + b;
16+
//cout<< punkte[i].y <<endl;
17+
return(0);
18+
}
19+
}

0 commit comments

Comments
 (0)