J
Jordan Abel
This will work with EBCDIC.
A-Z are in order in EBCDIC but are not contiguous.
This will work with EBCDIC.
>
> This will work with EBCDIC. It will even work, amazingly, with Baudot.
> In fact, it will even work with Morse code. When designing character
> sets, humans have a tendency to make A-Z contiguous. (Of course, for
> Baudot and Morse A-Z exists but there are no a-z).
How about this?
#include<stdio.h>
int main()
{
char scr;
printf("input the character: ");
scanf("%s", &scr);
if (scr >= 'A' && scr <= 'Z')
{
scr += 32;
}
if (scr >= 'a'&& scr <= 'z')
{
scr -= 32;
}
printf("the result is: %s", &scr);
return 0;
}
Simple code is ok, i think.
The IDE I used is Dev-C++ 4.9.9.0.
When designing character
sets, humans have a tendency to make A-Z contiguous.
Mark said:Er... What, you mean like abgdezeth ?
Thats a contiguous alphabetic sequence in the order which would make
perfect sense to millions of people.
(and lets not forget azerty....)
Mark McIntyre
Malcolm said:The hard part is addressing the screen. Virtually all C compilers
come with some sort of non-standard library for accessing character-
mapped screens.
Raster (addressable, modifiable pixels) devices attached to computers as"Dag-Erling Smørgrav" said:What is this "screen" you speak of? I've searched through my copy of
the standard but found no mention of it.
Raster (addressable, modifiable pixels) devices attached to computers as
output devices.
What is this "screen" you speak of?
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.