Strings: Looking at ASCII Code

Please support our C advertiser: Programming Forums - DaniWeb Sister Site
bumsfeld bumsfeld is offline Offline Aug 20th, 2005, 1:12 pm |
0
Commonly strings consist of ASCII characters, some are printable, some are in the backgrounds like the bell, carriage return, linefeed, tab and so forth. This code displays a table of ASCII characters and the corresponding decimal value. As always, you are encouraged to learn here.
Quick reply to this message  
C Syntax
  1. /* display the ASCII character table */
  2.  
  3. #include <stdio.h>
  4.  
  5. int main()
  6. {
  7. int k;
  8.  
  9. for ( k = 14; k < 256; k++ )
  10. {
  11. printf ( "%3d = %c ",k, k );
  12. }
  13.  
  14. getchar(); /* wait for key */
  15. return 0;
  16. }
0
bofarull bofarull is offline Offline | Mar 7th, 2006
Hi, can you do the same for UNICODE?

Bofarull
 
 

Message:


Thread Tools Search this Thread



Tag cloud for C
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC