The working mechanism of this source code is similar to above source code. But, it uses the function fopen() to open the file.txt file in reading mode i.e. function is called with “file.txt” and “r” as argument. After the file is opened in reading mode, the content of file.txt is displayed on the screen and file is closed.
This Program computes the transpose of the matrix and prints it on the screen as simply interchange the rows and columns of the matrix.
The internal execution of the program depends upon the entered Integer.After the successful compilation of the program, a message is displayed on the screen as Enter a number: if user entered 6 then compiler checks that 6 is greater than 0 therefore it is a positive number not negative or 0 therefore, again a message displayed on the screen as You entered a positive number.
The internal working of this program depends upon the length of the strings.After the successful compilation of the program, a message is displayed on the screen as Enter first string: User Enter Welcome Then, again a message displayed Enter second string: If second time user entered User then the final output is Concatenated string is WelcomeUser.
As we know that time is the most important concern in our life. To do any task easily, We have to use software to perform it in a simpler manner. Software is a set of programs with related documents. The Software Program or Program is a set of instructions to do a specific task.
The internal execution of the program depends upon the entered Integer.After the successful compilation of the program, a message is displayed on the screen as Enter a number in whose digits you want to count.If you entered 436 then again a message displayed as The number of digits in above integer is : 3
This program evaluates The ASCII value of inserted character. In this program, the user is asked to enter 'A' character. The character is stored in variable a. When %d format string is used, 65 (the ASCII value of G) is displayed. When %c format string is used, 'A' itself is displayed.
This program evaluates and Compute Quotient and Remainder when an integer is divided by another integer. In this program, the user is asked to enter two integers (dividend and divisor) which are stored in variable dividend and divisor respectively. Finally, the quotient and remainder are displayed as output.
In this Program, the if…else statement is used to check whether a character entered by the user is alphabet or not? The alphabets A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U, V, W, X, Y, and Z are called Alphabet. All other characters except these 26 letters are not an Alphabet. If User entered any character rather than 26 Alphabet than a print like # is not an alphabet.
In this Program, the if…else statement is used to check whether an alphabet entered by the user is a vowel or a constant. The five letters A, E, I, O and U are called vowels. All other letters except these 5 vowel letters are called consonants. This program assumes that the user will always enter an alphabetic character.
Never Miss an Articles from us.
Contribute the Community.