Logical Statements | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
- 4

Logical Statements

You're a tour manager and need a program that will identify small countries. A country is considered small if its population is under 10000 and its area is under 10000 hectares. The given program takes population and area as input. Task Complete the program to output "small country" if both conditions are met. Don't output anything otherwise. Sample Input 9955 7522 Sample Output small country Use && to combine conditions.

8th Sep 2021, 8:22 AM
Wienny Natalia
5 Answers
+ 2
Complete the program to output "small country" if both conditions are met. Don't output anything otherwise.
26th Dec 2022, 6:32 PM
Mostafa Khaled
0
You're a tour manager and need a program that will identify small countries. A country is considered small if its population is under 10000 and its area is under 10000 hectares. The given program takes population and area as input.
23rd Dec 2022, 2:14 PM
James Joshua
James Joshua - avatar
- 1
So you have two integers user input to get from user: population and area,so it will be easy to use if statement if population < 10000 && area < 100000 then print small country.
8th Sep 2021, 9:51 AM
HBhZ_C
HBhZ_C - avatar
- 2
input your sample in this code!!! https://code.sololearn.com/cTPMoQiQrQ0t/?ref=app
8th Sep 2021, 8:28 AM
Saurabh
Saurabh - avatar
- 2
Wienny Natalia Is this a challenge or your homework? If it is a challenge, then I can provide details of the correct way to place it on Sololearn. If it is homework then it is SPAM. Please reserve the Q&A forum for coding related questions pertaining to your personal difficulties
8th Sep 2021, 9:53 AM
Rik Wittkopp
Rik Wittkopp - avatar