DCP-28: Circle and Square Back to All Problems

Beginner Geometry > Basic Geometry


In this problem you have to do some basic school geometry problem solution. You will be given radius of a circle (**R**) and side of a square (**S**). You have to write a program to determine whether the square will perfectly fit inside the circle or not. Please check the following picture to get an understanding. ![circle and square][1] Input: ------ First line of the input will consist of an integer which represent the test case **T (0 &lt; T<=30)**. Each test case contains 2 positive fraction numbers R denoting the radius of the circle and S denoting the side of the square. You can assume **(0.00 &lt; R, S <=100.00)**. Output: ------- For each test case print **Yes** if the square will perfectly fit inside the circle, otherwise print **No**. Please consider only 2 decimal places in the final comparison for decision making. Sample Input ------------ 3 30.00 42.43 20.00 30.00 1.00 5.00 Sample Output ------------- Yes No No [1]: https://s3-ap-southeast-1.amazonaws.com/devskillimagestorage/questionimages/ab482c79-3818-c984-3ad0-08d2e28a520e_d686ac6d0a9b4df593e7cc4c5d6dc948_W225xH225.png


Problem Setter:

MD. Jalal Uddin

Please login to submit solution to this problem.

Problem Limits

Language Time Limit (seconds)
C 1.00
C++ 1.00
C++14 1.00
C# 2.00
Go 2.00
Java 2.00
JavaScript 2.00
Objective-C 2.00
Perl 2.00
PHP 2.00
Python 2.00
Python3 2.00
Ruby 2.00
VB.Net 2.00

Problem Stats

255/827

Solve/Submission

Ranking

# User Language Timing
01 rana_cse Cpp14 0.00s
02 ash12 Cpp14 0.00s
03 shawon100 Cpp 0.00s
04 I_See_You Cpp14 0.00s
05 MAHRahat Cpp14 0.00s
06 PKP_007 Cpp14 0.00s
07 absa1am Cpp14 0.00s
08 subhashis_cse Cpp14 0.00s
09 Core_i14 Cpp14 0.00s
10 Saimum_140128 Cpp14 0.00s
11 Nazmul_WUB Cpp14 0.00s
12 pusku Cpp 0.00s
13 emrul Cpp14 0.00s
14 sherina Cpp 0.00s
15 ronok_cse Cpp14 0.00s
16 reza_ul Cpp14 0.00s
17 maxhasan Cpp14 0.00s
18 shishir09 Cpp 0.00s
19 joy25896 Cpp14 0.00s
20 wizard Cpp14 0.00s
21 non_coder C 0.00s
22 shahad_mahmud Cpp14 0.00s
23 afzalul Cpp14 0.00s
24 onucsecu Cpp14 0.00s
25 virus Cpp14 0.00s
26 feodorv Cpp 0.00s
27 anik_JU Cpp14 0.00s
28 Mr_KAJOL Cpp 0.00s
29 Mhkhaled Cpp14 0.00s
30 Sayma_COU Cpp 0.00s
31 rakibmahmud Cpp14 0.00s
32 mir003 Cpp 0.00s
33 terminator_c Cpp14 0.00s
34 rabib Cpp14 0.00s
35 jayed_al_hasan Cpp14 0.00s
36 gulzar Cpp14 0.00s
37 seyedssz Cpp14 0.00s
38 golapraj Cpp14 0.00s
39 Kira Cpp14 0.00s
40 MohammadShamim Cpp14 0.00s
41 Iqbal1013 Cpp14 0.00s
42 sadia2427 Cpp14 0.00s
43 Khayrul_34 Cpp14 0.00s
44 nazmul_bzs Cpp14 0.00s
45 DynamicOvi Cpp 0.00s
46 mh4746 Cpp14 0.00s
47 serious_sam Cpp14 0.00s
48 gsshanto Cpp14 0.00s
49 zubayerhossain Cpp 0.00s
50 lolcoder Cpp14 0.00s
Feedback

Your feedback is our precious!



Or call +88 02 9853138 for support