Programming Examples

Python program to define a list of countries that are a member of BRICS Check whether a county is member of BRICS or not


Write a python program to define a list of countries that are a member of BRICS. Check whether a county is member of BRICS or not

Solution

country=["India", "Russia", "Srilanka", "China", "Brazil"]
is_member = input("Enter the name of the country: ")
if is_member in country:
	print(is_member, " is the member of BRICS")
else:
	print(is_member, " is not a member of BRICS")
Output

Enter the name of the country: India

India is the member of BRICS

----------------------------------------------

Enter the name of the country: Japan

Japan is not a member of BRICS

CCC Online Test 2021 CCC Practice Test Hindi Python Programming Tutorials Best Computer Training Institute in Prayagraj (Allahabad) Best Java Training Institute in Prayagraj (Allahabad) Best Python Training Institute in Prayagraj (Allahabad) O Level Online Test in Hindi Bank SSC Railway TET UPTET Question Bank career counselling in allahabad Sarkari Naukari Notification Best Website and Software Company in Allahabad Sarkari Exam Quiz