Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 What is this and what is its purpose?
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
TheCatsMeow




PostPosted: Mon Jan 24, 2011 2:13 pm   Post subject: What is this and what is its purpose?

So in my comp. sci. class, we were given an exam review booklet. One of the questions asks us to identify something and explain the purpose of it.

Example: %, <, +, :=

My question is.. What is :# and what is it used for? Does it even exist?
Sponsor
Sponsor
Sponsor
sponsor
Tony




PostPosted: Mon Jan 24, 2011 2:27 pm   Post subject: RE:What is this and what is its purpose?

Those are all operators. Yes, := exists. It's probably used in just about every piece of an example code.
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
ProgrammingFun




PostPosted: Mon Jan 24, 2011 2:43 pm   Post subject: RE:What is this and what is its purpose?

Is it just me or does the one he/she is asking for look like :# Confused
2goto1




PostPosted: Mon Jan 24, 2011 3:04 pm   Post subject: RE:What is this and what is its purpose?

Interesting, what was the programming language of the test? I haven't seen :# before.
Insectoid




PostPosted: Mon Jan 24, 2011 3:05 pm   Post subject: RE:What is this and what is its purpose?

I vaguely remember being able to add that to the end of a put to format it differently, but that's very vague and might be completely different.
Tony




PostPosted: Mon Jan 24, 2011 3:14 pm   Post subject: RE:What is this and what is its purpose?

if :# means :<number> such as :4 then yes, it could be used to format strings for put statements. Something like
code:

put "foo":10, "bar"
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
2goto1




PostPosted: Mon Jan 24, 2011 3:29 pm   Post subject: RE:What is this and what is its purpose?

Ah, could be. I guess without seeing the original question it's hard to say, good catch
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 7 Posts ]
Jump to:   


Style:  
Search: