Datahub
数据改变生活

14578: Circle

发表时间:2022-10-27 20:10

14578: Circle

时间限制: 1 Sec   内存限制: 128 MB
提交状态

题目描述

Given is an integer r.
How many times is the area of a circle of radius r larger than the area of a circle of radius 1?
It can be proved that the answer is always an integer under the constraints given.

Constraints
·1≤r≤100
·All values in input are integers.

输入

Input is given from Standard Input in the following format:

r

输出

Print the area of a circle of radius r, divided by the area of a circle of radius 1, as an integer.

样例输入 Copy

【样例1】

2

【样例2】

100

样例输出 Copy

【样例1】

4

【样例2】

10000

提示

样例1解释
The area of a circle of radius 2 is 4 times larger than the area of a circle of radius 1.
Note that output must be an integer - for example, 4.0 will not be accepted.

#include<bits/stdc++.h>

using namespace std;

int main(){

    int x;

    cin>>x;

    cout<<x*x<<endl;

    return 0;

}


文章分类: 算法例题
分享到:
QQ:258506508                                     联系电话:020-000000    000-000000                                   联系邮箱:xxx@.co.m                                     联系地址:XXX省XXX市XXX县XXX路