Answer:
Following are the program to this question:
#include <stdio.h>//using the header file
int main()//main method
{
int y;//defining integer variable y
printf("Enter year value:");//print message
scanf("%d", &y);//use input method for input year value
if (y>= 2101)//defining if block that checks year greater then 2101
printf("Distant future");//print message
else if (y>= 2001)//defining else if block that checks year greater then 2001
printf("21st century"); //print message
else if (y>= 1901)//defining else if block that checks year greater then 1901
printf("20th century");//print message
else //defining else block
printf("Long ago");//print message
return 0;
}
Output:
Enter year value:1998
20th century
Explanation:
In the given C language code, inside the main method, an integer variable "y" is defined, which allows the user to input the year value, and use the multiple conditions to check the given value and print message when the condition is matched.
- Inside the "if" condition block, it checks the "y" variable value is greater and equal to 2101. so, it will print "Distant future", otherwise go to the next condition.
- In this, if "y" value is greater than equal to "2001", it will print the message "21st century", otherwise go to the next condition.
- In this, If the value of "y" is greater than equal to "1901", it will print the message "20th century", and if all the above condition is not true, then it will go to the else block, and it will print "Long ago" as the message.
Answer:
Explanation:
check the attachment for the solution.
1) graphical notation for a telephone object class.
2) a messaging system on a mobile
3) a personal computer
4) a bank account
5) a library catalog
6) personal stereo
Solution:
The Bureau of Labor Statistics (BLS) of the U.S. Department of Labor is the principal federal agency responsible for measuring labor market activity, working conditions, and price changes in the economy. Its mission is to collect, analyze, and disseminate essential economic information to support public and private decision making. As an independent statistical agency, BLS serves its diverse user communities by providing products and services that are accurate, objective, relevant, timely, and accessible.
This is the required answer.
Answer:
Consider the following code:
if (x > 5 AND x <= 10):
print(OK)
Click all the mistakes that apply:
AND should be and
The print (OK) should be print ("OK")
The blue section of the following Venn diagram could represent which of the following Boolean statements?
not
The following code will not compile. Which of the options below would allow the code to compile and run as intended?
if (x >= -10 and <= 10):
print("In range")
if (x >= -10 and x <= 10):