By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
457,633 Members | 1,053 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 457,633 IT Pros & Developers. It's quick & easy.

Moving pointers backwards and forwards

P: n/a
What are the issues involved in using pointers to move forward and
backward strings and other data types? How do you include effeciency,
security and manageability?

cman

Mar 2 '07 #1
Share this Question
Share on Google+
4 Replies


P: n/a
cman wrote:
What are the issues involved in using pointers to move forward and
backward strings and other data types?
None, if you know what you're doing.
How do you include effeciency,
security and manageability?
What makes pointers mutually exclusive with efficiency, security and
all the rest of it?

Mar 2 '07 #2

P: n/a
"cman" <ti****@gmail.comwrites:
What are the issues involved in using pointers to move forward and
backward strings and other data types? How do you include effeciency,
security and manageability?
How many points is this homework question worth? What is your
instructor's e-mail address, so we can submit our answers directly?

--
Keith Thompson (The_Other_Keith) ks***@mib.org <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <* <http://users.sdsc.edu/~kst>
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"
Mar 2 '07 #3

P: n/a
cman wrote On 03/02/07 15:30,:
What are the issues involved in using pointers to move forward and
backward strings and other data types?
1) When moving forward, you may step one place beyond
the end of the array but no farther.

1a) Having reached the place just after the array, you
must not attempt to read or write that non-existent spot.

2) When moving backward, you must not step beyond the
beginning of the array. Note that this produces an asymmetry
in the way forward-stepping and backward-stepping loops are
written.
How do you include effeciency,
security and manageability?
Exactly as you do with `int' and `double' and `struct tm'.

--
Er*********@sun.com
Mar 2 '07 #4

P: n/a
This was not a homework question.

cman
On Mar 3, 2:05 am, Keith Thompson <k...@mib.orgwrote:
"cman" <til...@gmail.comwrites:
What are the issues involved in using pointers to move forward and
backward strings and other data types? How do you include effeciency,
security and manageability?

How many points is this homework question worth? What is your
instructor's e-mail address, so we can submit our answers directly?

--
Keith Thompson (The_Other_Keith) k...@mib.org <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <* <http://users.sdsc.edu/~kst>
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"

Mar 3 '07 #5

This discussion thread is closed

Replies have been disabled for this discussion.