Compare putchar function with the getchar function, Computer Engineering

Assignment Help:

Compare putchar function with the getchar function.

The following program uses getchar to copy the first word from a line of input entered at the terminal's keyboard. Then, it displays the word on the terminal's screen.

 #include

int c;

main()

{

puts("Enter some words on a line.");

/* Look for white space */

while ((c != ' ') && (c != '\t') && (c != '\n'))

{

c = getchar();

putchar(c);

}

putchar('\n');

}

 


Related Discussions:- Compare putchar function with the getchar function

What is the basic approach of page replacement, What is the basic approach ...

What is the basic approach of page replacement?  If no frame is free is available, find one that is not currently being used and free it. A frame can be freed by writing its co

Explain why the ROM is a volatile memory, Is the ROM a volatile memory? Exp...

Is the ROM a volatile memory? Explain Ans. No, ROM is a Non-Volatile memory. Programming of ROM includes making of the needed  interconnections at  the time of fabrication and

Dynamic screen sequence, Dynamic screen sequence  for a  screen can be set ...

Dynamic screen sequence  for a  screen can be set using which commands? It uses two commands:- A) Set Screen B) Call screen.

Determine the decimal equivalent of binary number, The decimal equivalent o...

The decimal equivalent of Binary number 11010 is ? Ans. 11010 = 1 X 2 4 + 1 X 2 3 + 0 X 2 2 + 1 X 2 1 = 26.

What is requisitepro, Rational RequisitePro is a needed management tool tha...

Rational RequisitePro is a needed management tool that helps project teams control the development process. RequisitePro organizes your requirements by linking Microsoft Word to a

Meaning of all variable, A project having of a set of jobs and a set of pre...

A project having of a set of jobs and a set of precedences, where precedence (i; j) show that job j cannot begin before job i is completed. Let c i be the duration of job i. We wi

Determine the benefits of developing prototype, Determine the benefits of d...

Determine the benefits of developing prototype According to SOMM [96] benefits of developing prototype are as following:  1.  Communication gap between clients and software

Differentiate concurrent and parallel executions, Differentiate concurrent ...

Differentiate concurrent and parallel executions ? The words "parallel "and "concurrent" are often used interchangeably, however they are different. Parallel execution is connec

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd