FREE Subscription to Dr. Dobb’s Digest: Same Great Content, New Digital Edition
Site Archive (Complete)
C++
Email
Print
Reprint

add to:
Del.icio.us
Digg
Google
Furl
Slashdot
Y! MyWeb
Blink
January 01, 2006

Ch: A C/C++ Interpreter for Script Computing

(Page 2 of 10)

January, 2006: Ch: A C/C++ Interpreter for Script Computing

Example 1: Array-boundary checking in Ch.

> int a[5] = {10,20,30,40,50} 
> a[-1] 
WARNING: subscript value -1 less than lower limit 0 
10 
> a[5] 
WARNING: subscript value 5 greater than upper limit 4 
50 
> char s[5] 
> strcpy(s, "abc") 
abc 
> s 
abc 
> strcpy(s, "ABCDE") 
ERROR: string length s1 is less than s2 in strcpy(s1,s2) 
ABCD 
> s 
ABCD

Previous Page | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 Next Page
TOP 5 ARTICLES
No Top Articles.



MICROSITES
FEATURED TOPIC

ADDITIONAL TOPICS

INFO-LINK