Sign in to follow this  
Cornel Iulian

[C] Afisarea a celor 256 caractere ale codului ASCII extins [Limbaj C]

1 post in this topic

Cerinta: Sa se scrie un program C care sa afiseze toate cele 256 caractere ale codului ASCII extins: pe cate o linie nr. de ordine in tabelul ASCII si caracterul aferent. Afisarea trebuie sa se opreasca astfel incat sa permita citirea tabelului ecran cu ecran, invitand operatorul sa actioneze o tasta pentru a continua. Se va tine cont ca pe ecran se pot afisa 25 de linii.

#include <stdio.h>
#include <conio.h>
int main()
{
	int i;
	for(i=0; i<=255; i++)
	{
		printf("%d -> %c \n",i,i);
		if((i+1)%23==0)
		{
			printf("\nApasati o tasta pentru a continua...\n");
			getch();
		}
	}
	return 0;
}

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this