Home
Ivan Sorokin's LJ - C++

> Recent Entries
> Archive
> Friends
> User Info

Advertisement

June 7th, 2009


Previous Entry Add to Memories Tell a Friend Next Entry
06:03 pm - C++
Write a standards-conforming C++ program containing a sequence of at least ten different consecutive keywords not separated by identifiers, operators, punctutation characters, etc.

Here is a good starting point:

signed long int const volatile a;

Maybe I hear you say "You can add extern to that" or perhaps "Make it the return-type of a function and add qualifiers"? Good idea:

extern inline signed long int const volatile f();

Ah, and we could explicitly instantiate a template... and it could be an operator:

template
extern inline signed long int const volatile operator
*(X&);


http://www.vandevoorde.com/C++Solutions/
Current Music: Rhapsody of Fire - Dawn of Victory

(Leave a comment)

Comments:


[User Picture]
From:[info]sadko4u
Date:June 7th, 2009 07:12 pm (UTC)
(Link)
template extern inline signed long int const volatile operator new(int, int, int, int);
[User Picture]
From:[info]ivansorokin
Date:July 8th, 2009 11:02 pm (UTC)
(Link)
10 слов, круто. :-)

> Go to Top
LiveJournal.com