mirror of
https://github.com/Kiritow/OJ-Problems-Source.git
synced 2024-03-22 13:11:29 +08:00
Create 1631.c
This commit is contained in:
parent
2d00ec1698
commit
c22d476980
22
QUSTOJ/1631.c
Normal file
22
QUSTOJ/1631.c
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
|
char save[] = "`1234567890-=QWERTYUIOP[]\\ASDFGHJKL;\'ZXCVBNM,./";
|
||||||
|
char maps[512];
|
||||||
|
char data[512];
|
||||||
|
|
||||||
|
int main()
|
||||||
|
{
|
||||||
|
for ( int i = 1 ; save[i] ; ++ i )
|
||||||
|
maps[save[i]] = save[i-1];
|
||||||
|
|
||||||
|
while ( gets(data) ) {
|
||||||
|
for ( int i = 0 ; data[i] ; ++ i )
|
||||||
|
if ( data[i] == ' ' || data[i] == ' ' )
|
||||||
|
printf("%c",data[i]);
|
||||||
|
else printf("%c",maps[data[i]]);
|
||||||
|
printf("\n");
|
||||||
|
}
|
||||||
|
return 0;
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user