/*
get_str( str, size ):
set k to 0
while 1 == 1
read c
if c ==
\n then
break
if k > size-2 then
print error
break
set str[k] to c
set k to k+1
set str[k] to null character
end
copy_first_name(full_name, first_name):
set k to 0
set length to strlen(full_name)
while k < length
if full_name[k] == ' ' then
break
set first_name[k] to full_name[k]
set k to k+1
set first_name[k] to null character
end
reverse_str(str1, str2):
set k to 0
set length to strlen(str1)
while k < length
set str2[length-k-1] to str1[k]
set k to k+1
end
This
preview
has intentionally blurred sections.
Sign up to view the full version.
is_same(str1, str2):
set length to strlen(str1)
if strlen(str2) != length

This is the end of the preview.
Sign up
to
access the rest of the document.
- Spring '11
- aren
- k+1
-
Click to edit the document details