1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
seraphim [82]
3 years ago
6

Who knows coding questions? Please help! Thanks.

Computers and Technology
1 answer:
Brut [27]3 years ago
6 0
<span>Write a program that prints ‘Hello World’ to the screen.Write a program that asks the user for her name and greets her with her name.Modify the previous program such that only the users Alice and Bob are greeted with their names.<span>Write a program that asks the user for a number n and prints the sum of the numbers 1 to n</span><span>Modify the previous program such that only multiples of three or five are considered in the sum, e.g. 3, 5, 6, 9, 10, 12, 15 for n=17</span><span>Write a program that asks the user for a number n and gives him the possibility to choose between computing the sum and computing the product of 1,…,n.</span>Write a program that prints a multiplication table for numbers up to 12.<span>Write a program that prints all prime numbers. (Note: if your programming language does not support arbitrary size numbers, printing all primes up to the largest number you can easily represent is fine too.)</span>Write a guessing game where the user has to guess a secret number. After every guess the program tells the user whether their number was too large or too small. At the end the number of tries needed should be printed. I counts only as one try if they input the same number multiple times consecutively.<span>Write a program that prints the next 20 leap years.</span></span>
You might be interested in
C programming question:
denpristay [2]

Answer:

You should do this:

if (0==strcmp(modelName,"Extravagant") && modelYear >= 1999 && modelYear <= 2002)

printf("%s\n","RECALL");

Explanation:

Lets consider this program and analyze the output.

int main()

{

int modelYear;

char modelName[30];

printf("enter the year");

scanf("%d",&modelYear);

printf("enter the modelname");

scanf("%s",modelName);

if (0==strcmp(modelName,"Extravagant") && modelYear >= 1999 && modelYear <= 2002)

printf("%s\n","RECALL");    }

if (0==strcmp(modelName,"Extravagant") && modelYear >= 1999 && modelYear <= 2002)

This statement has a function strcmp  which is used to compare two strings.

If the user enters Extravagant as model name then this input will be compared by the string stored in modelName i.e. Extravagant, character by character. If the string entered by the user matches the string stored in modelName this means this part of the if condition evaluates to true. 0==strcmp means that both the strings should be equal.

The next part of the if statement checks if the model year entered is greater than or equal to 1999 AND less than or equal to 2002. This means that the model year should be between 1999 and 2002 (inclusive).

&& is the logical operator between both the parts of if statement which means that both should evaluate to true in order to display RECALL.

This is correct way to use because the if (modelName == "Extravagant" && modelYear >= 1999 && modelYear <= 2002)  printf("%s\n","RECALL"); statement will not display RECALL. After entering the model name and model year it will move to the next line and exit.

So in if (0==strcmp(modelName,"Extravagant") && modelYear >= 1999 && modelYear <= 2002)

printf("%s\n","RECALL"); statement when the if condition evaluates to true, then RECALL is displayed in the output.

6 0
3 years ago
How can you tell that a website is valid and reliable 10 points
Dmitry_Shevchenko [17]

Answer:

if it uses the CARS checklist

6 0
3 years ago
Send a document as a PDF when A. you want the recipient to make changes to the file. B. it needs to be printed. C. it contains m
Julli [10]
A PDF must be put into an external program after being exported to be edited, you can't make direct changes to it. This eliminates answer choice A.

You can print documents with other extensions besides .pdf, such as those of Word documents and such, it doesn't have to be a .pdf. This eliminates answer choice B.

Since you can't directly edit a PDF, C is a possible answer.

Files don't have to be saved as a .pdf, especially just for the first time. Whenever you save a file, first time or not, you can save it as anything, and there's no reason to have to save it as a .pdf. This eliminates answer choice D.

So the answer is C. it contains material you don't want changed.

Hope this helps!
3 0
3 years ago
Give three general reasons for the importance of computer networking.
LiRa [457]
I think the First reason is; it provides the best way of business communication.
Second reason, streamline communication
Third reason cost effective resource sharing :) (hope this helps)
5 0
2 years ago
What is RAM? explain it
Zina [86]
RAM is memory in the computer
3 0
3 years ago
Read 2 more answers
Other questions:
  • You can avoid culture shock by ____________.
    10·2 answers
  • Assuming that t is an array and tPtr is a pointer to that array, which expression refers to the address of element 3 of the arra
    7·1 answer
  • Assume that the following method header is for a method in class A.
    15·1 answer
  • When changing lanes on an expressway signal your intentions and?
    8·1 answer
  • CMS is a content management system that collects, organization, publishes, and manages creative content. Right...?
    9·1 answer
  • What type of formula uses data from multiple worksheets
    6·1 answer
  • What blockchain implementation resulted from bitcoin’s rejection of a recommendation to enhance its scripting language support?
    9·1 answer
  • Read the introduction (paragraphs 1-3].
    7·1 answer
  • Assignment 10 - 1/0 Streams and Files Create a C++ a program that will compute the average word length (average number of charac
    13·1 answer
  • How to give a file name as an argument in function in python.
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!