POV-Ray : Newsgroups : povray.general : JPovRay ... offtopic Server Time
1 Nov 2024 07:25:33 EDT (-0400)
  JPovRay ... offtopic (Message 1 to 2 of 2)  
From: Case
Subject: JPovRay ... offtopic
Date: 13 Oct 1999 16:04:04
Message: <3804E656.36A318AA@sh.cvut.cz>
Thanks for all reminders. Especially thanks to N. Juha for hints.

... And, I really marvel his never ending love to
iterators,adaptors,allocators and other cool STL stuff ;-) ...

Have a good day

Case


Post a reply to this message

From: Nieminen Juha
Subject: Re: JPovRay ... offtopic
Date: 14 Oct 1999 10:14:07
Message: <3805e52f@news.povray.org>
Case <p.k### [at] shcvutcz> wrote:
: ... And, I really marvel his never ending love to
: iterators,adaptors,allocators and other cool STL stuff ;-) ...

  What's the problem with them? You don't have to use them if you don't want
to. Iterators are handy.
  Make this with java:

#include <iostream>
#include <map>
#include <string>
using namespace std;
int main()
{ typedef map<string,unsigned> wlist_t;
  wlist_t words;
  string word;
  while(cin) { cin >> word; words[word]++; }
  for(wlist_t::iterator i=words.begin(); i!=words.end(); i++)
    cout << i->first << ": " << i->second << endl;
}

(It reads text from standard input and ouputs all the words used in the
text in alphabetical order and the number of times it's used; it does it
very fast regardless of the size of the input)

  Of course making it with java would certainly be easier than with C... :)

-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):5;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.