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
Assoli18 [71]
3 years ago
6

5. ADD A STATEMENT OR STATEMENTS to the program on the following page (including constant and/or variable declarations if you wa

nt) so that the output is the single character 1 followed by a newline. Statements in the execution body of the program must NOT include any literal constants (numeric, Boolean or char); however, you may declare named constants and/or initialize variables in the declaration section of the program. In the program body, you must use at least TWO declared symbolic names (variables or named constants), and you are ABSOLUTELY FORBIDDEN to use anything like the following statement: printf("1\n"); On the other hand, you are encouraged to use a printf statement that outputs the result of a Boolean expression (which output will be either 1 or 0). If you aren't confident of your answer, type in, compile and run the resulting C program to test it.
Computers and Technology
1 answer:
kvasek [131]3 years ago
4 0

Answer:

C code is explained below

Explanation:

#include <stdio.h>

int main() { /* main */

/*

      **********************************************************

      * Declaration Section

      **********************************************************

      *

      * Named Constants

      */

  const int bits_per_byte = 8;

  const int attention_span_in_seconds = 3;

  /*

  * You can insert stuff after this comment.

*/

/*

* Local variables

*/

  int modem_send_speed_in_bits_per_second = 56000;

  int script_file_length_in_bytes = 28000;

  int seconds_to_send_script_file;

  /*

  * You can insert stuff after this comment.

*/

/*

      **********************************************************

      * Execution Section

      **********************************************************

      *

      * You can insert stuff after this comment.

*/

  seconds_to_send_script_file =

      (script_file_length_in_bytes * bits_per_byte) /

      modem_send_speed_in_bits_per_second;

  if (attention_span_in_seconds < seconds_to_send_script_file)

      printf("1\n");

  else printf("0\n");

} /* main */

You might be interested in
Brake fluid is made up of a chemical that
Sidana [21]

Answer:

Most brake fluids used today are glycol-ether based, but mineral oil (Citroën/Rolls-Royce liquide hydraulique minéral (LHM)) and silicone-based (DOT 5) fluids are also available.

Explanation:

4 0
3 years ago
Network layer protocols specify the _______ structure and processing used to carry data between hosts.
kari74 [83]

Network layer protocols specify the  <u>packet structure</u> and processing used to carry data between hosts.

<h3>What is the Network layer protocols  about?</h3>

The header, payload, as well as the trailer of a network packet are its three component pieces. The underlying network architecture or protocol employed determines the format and size of a network packet. A network packet resembles a package in concept.

Therefore, Network layer protocols define the packet format and processing needed to transfer data from one host to another host, in contrast to the Transmission layer (OSI Layer 4), which controls the data transport between the programs operating on each end computer.

Learn more about Network layer from

brainly.com/question/14476736
#SPJ1

3 0
1 year ago
Enrico waited ten years to file a cause of action against Frederico for a breach of contract claim. Frederico can use ______ as
ser-zykov [4K]
Time, due to the amount of time between the initial action and the filing of the report, federico could claim the it didn't happen or something
3 0
3 years ago
What is printed by the following program? var numApples = 10; var numOranges = 5; if(numApples &lt; 20 || numOranges == numApple
Travka [436]

Answer:

The output of the following code is "Hello, we are open! Sincerely, the grocery store ".

Explanation:

In the given code firstly we declare the variable that is numApples and numOranges. In this variable we assign value and the datatype of the variable is var. The var datatype can hold any type of data. Then we use the conditional statement. In the conditional statement, we use the OR logical operator. In the if block we check the condition that is if numApples variable value is less then 20 OR numOranges variable value is equal to numApples then it will print "Hello, we are open!". In the else block it will print "Sorry, we are closed!". In the last, we print "Sincerely, the grocery store".So in this question, if block is executed and the additional message is printed.

6 0
3 years ago
 A network engineer is examining a configuration implemented by a new intern who attached an IP phone to a switch port and confi
lakkis [162]
Where is the answer?????????

7 0
3 years ago
Other questions:
  • What happens when you press Ctrl Alt Delete twice?
    12·1 answer
  • Suppose the information content of a packet is the bit pattern 1110 0110 1001 1101 and an even parity scheme is being used. What
    15·1 answer
  • Which type of message format is designed to arouse curiosity, not showing the product or delivering quite enough information to
    10·1 answer
  • When you tell a computer what to do, you are providing input?
    11·1 answer
  • The picture that graphically represents the items you use in Windows is called a/an
    15·1 answer
  • What is the subnet mask ?
    9·2 answers
  • If you will be giving your presentation to an audience, you can practice your presentation by using View, ___________, to rehear
    14·1 answer
  • Why does everyone refer to dogs as being loyal
    11·2 answers
  • Retype and run, note incorrect behavior. Then fix errors in the code, which should print num_stars asterisks.
    9·1 answer
  • A customer would like you to install a high-end video card suitable for gaming. Your installation and configuration SHOULD inclu
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!