Ответ:
Python:
n = int(input())
s = 0
for i in range(1, n+1):
s += n
print(s)
C++:
#include <iostream>
using namespace std;
int main(){
int n, s = 0;
cin >> n;
for(int i = 1; i <= n; i++) s += n;
cout << s;
}
Copyright © 2024 SCHOLAR.TIPS - All rights reserved.
Answers & Comments
Ответ:
Python:
n = int(input())
s = 0
for i in range(1, n+1):
s += n
print(s)
C++:
#include <iostream>
using namespace std;
int main(){
int n, s = 0;
cin >> n;
for(int i = 1; i <= n; i++) s += n;
cout << s;
}