Question

we know getc() could be a function or a macro , please take example by code...

we know getc() could be a function or a macro , please take example by code for each one  

Homework Answers

Answer #1

getc() is one of the inbuilt functions which is used to reads the characters of the file.

getc() can be used in macro than a function.

It returns the next character of the file and it also returns end of file ( EOF).

Refer the below code using getc():

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
Problem: Our Armstrong number Please write code for C language So far we have worked on...
Problem: Our Armstrong number Please write code for C language So far we have worked on obtaining individual digits from 4 digits or 5 digit numbers. Then added them to find the sum of digits in various examples and assignments. However, the process of extracting individual digits is actually can be solved using a loop as you were doing a repetitive task by using mod operation and division operation. Now, we know how loops work and we can remove the...
Please write the python code for a function called called count_all_words that takes a phrase as...
Please write the python code for a function called called count_all_words that takes a phrase as an argument and counts each unique word in the phrase. The function should return a list of lists, where each sub-list is a unique [word, count] pair. (See example below.) Hint: A well-written list comprehension can solve this in a single line of code, but this approach is not required.
using matlab please present code for the following (ALL PARTS PLEASE AND THANK YOU) 1. No...
using matlab please present code for the following (ALL PARTS PLEASE AND THANK YOU) 1. No Input/No Output Write a function that has no input and no outputs. This function will simply display some text when it is called. (this is my code, are there suggestions for improvements?) function Display() disp('some text') end 2. 1 Input/No Outputs Write a function with one input and no outputs. This function will simply display a variable that is provided as an input argument....
Give an example of how companies adapted themselves about changing macro-environments during Covid-19. please write specific...
Give an example of how companies adapted themselves about changing macro-environments during Covid-19. please write specific example in your own words
Normal distribution could be used to approximate the binomial distribution under certain conditions. We already know...
Normal distribution could be used to approximate the binomial distribution under certain conditions. We already know the binomial probability distribution formula, so why is it necessary to learn this one? When is it useful to approximate the binomial distribution as normal? Provide an example.
using dr.racket programing language If we write a function that tests whether a list contains only...
using dr.racket programing language If we write a function that tests whether a list contains only strings, odd numbers, or even numbers, you will notice that the code that iterates through the list stays the same, with the only change being the predicate function that checks for the desired list element. If we were to write a new function for each of the tests listed above, it would be more error-prone and an example of bad abstraction. We could write...
1. Please use a single example that uses the If ---Then---Else statement to code single-alternative and...
1. Please use a single example that uses the If ---Then---Else statement to code single-alternative and dual-alternative selection structures. 2. SELECT CASE (include case else statement) vs. IF....ELSE..block, give an example of how to use each structure Please keep it as simple as possible!
could someone please explain this code and the output to me? #include <stdio.h> #include <unistd.h> int...
could someone please explain this code and the output to me? #include <stdio.h> #include <unistd.h> int main(void) { printf("one\n"); fork(); printf("two\n"); return 0; }
What is the difference between a module and a function? Give one example of each either...
What is the difference between a module and a function? Give one example of each either with pseudo code or a short description.
c++ code for function that take doubly linked list as parameter and deleted all nodes in...
c++ code for function that take doubly linked list as parameter and deleted all nodes in even position from first to last
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT