Untitled
unknown
c_cpp
a year ago
366 B
1
Indexable
Never
#include <iostream> using namespace std; int main() { int a; int b; int c; int y = 0; int max = -1; int min = 9; cin >> a >> b >> c; for (int i = 0; i <= b;i+=c) { y = 2 * i + 1; cout << y << endl; if (y > max) { max = y; } if (y < min) { min = y; } } cout << "min - " << min << " " << "max - " << max; }