Answer to Question #208880 in C for Prasanna S.K

Question #208880

Develop a C program for File Operations that stores n number of the Alphabets from A to Z in a file and display it.



Input :

11

80


Output :

P

Q

R

S

T

U

V

W

X

Y

Z


1
Expert's answer
2021-06-20T08:12:00-0400
#include <stdio.h>
#include <stdlib.h>


void main( void){
	FILE *fpFileAlphabets;
	int numberLetters;
	int startLetter;
	int letterASCII;
	scanf("%d",&numberLetters);
	scanf("%d",&startLetter);
	fpFileAlphabets = fopen("Alphabets.txt", "w+");
	printf("\n");
	for(letterASCII=startLetter;letterASCII<startLetter+numberLetters;letterASCII++){
		fprintf(fpFileAlphabets,"%c\n",letterASCII);
		printf("%c\n",letterASCII);
	}
	fclose(fpFileAlphabets);
	getchar();
	getchar();
}




Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS