Post Reply 
define questions
06-21-2017, 03:17 PM
Post: #4
RE: define questions
You defined INC2 as X+2. That would mean I'd have to use it as in n:=INC2(n);
I see what you are saying....n is local to INC2, so I'd have to use it this way. I wanted to be able to increment a variable without having to type the variable twice, as in x:=x+1;
....kind of like ++x; in C.
I might as well type in n:=n+2 rather than n:=INC2(n);
I can create a regular program to do it. It would have been nice to define a function though (more elegant), where I can whip out quickly common functions that I use a lot. I've had a thought though, (possibly using 'n' as an argument, which "kind" of works like passing in a pointer)....need to experiment a little. I'll post if I can get it to work.
Thx
-D
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
define questions - webmasterpdx - 06-21-2017, 12:31 PM
RE: define questions - Tim Wessman - 06-21-2017, 02:04 PM
RE: define questions - DrD - 06-21-2017, 02:14 PM
RE: define questions - webmasterpdx - 06-21-2017 03:17 PM
RE: define questions - Didier Lachieze - 06-21-2017, 11:07 PM
RE: define questions - DrD - 06-21-2017, 09:19 PM
RE: define questions - AlexFekken - 06-22-2017, 02:12 AM
RE: define questions - webmasterpdx - 06-22-2017, 12:05 PM



User(s) browsing this thread: 1 Guest(s)