mbhtkn3191 mbhtkn3191
  • 18-10-2019
  • Computers and Technology
contestada

write a program to print all the ASCII values and their equivalent characters using a while loop.
the ASCII values vary from 0 to 255.

Respuesta :

joaobezerra joaobezerra
  • 18-10-2019

Answer:

I am going to write a C program. The program is in the explanation. You use a simple while loop controled by a counter(don't forget to initialize nor increment the counter). Inside the while loop, you printf the ASCII value as a %d and the equivalent character as a %c.

Explanation:

#include <stdio.h>

int main(){

int i = 0;

/*While loop*/

while(i < 256){

printf("ASCII value: %d\n", i);

printf("ASCII character: %c\n", (char)i);

i++;

}

return 0;

}

Answer Link

Otras preguntas

what are those organizational entry problems?​
Francis buys a package of 450 plastic forks. he uses 315 of the plastic forks. What percent of plastic forks did Francis use? show your work.​
Design Report Design a Thermos It’s time to complete your Design Report. Save the lab to your computer with the correct unit number, lab name, and your name at
Which ones are physical change and which ones are chemical reactions: Evaporation, condensation, melting, combustion, neutralization
Carl drove 400 km of 1200 km trip. What percent of the trip did he complete?
For each sequence of DNA is shown. Write the complementary RNA sequence underneath the letters, then use the codon chart to determine the amino acid sequence:
HELP!!!!!!! pls also give a GOOD explanation
Choose the congruence theorem that you would use to prove the triangles congruent.
Help me please and thank you! Question is below!
AyudaaaaaaaaaaaaaaAaa