• View unanswered postsView active topics

  • Birthdays

    All the rest (non-gaming) topics

    Postby Metalor 15 Mar 2015, 09:15

    Indeed, Happy Spirit Journey Formation Anniversary Linuxwolf! Your coding talents give individuals like myself something to look up to. Batman: No Man's Land was a fine feat of Wolf-engineering.
    Metalor

     
    Posts: 190

        

    Postby Dean 15 Mar 2015, 09:20

    Happy Birthday LinuxWolf! Have a frothy or 2 on me!! :D :beer:
    Dean
    User avatar

     
    Posts: 1266
    Location: Australia

        

    Postby linuxwolf 15 Mar 2015, 10:42

    Thanks everyone! :friends:
    linuxwolf
    User avatar

     
    Posts: 4880
    Location: Australia

        

    Postby DoomJedi 14 Mar 2016, 14:08

    Code: Select all
    #include <BirthdayCake.h>

    int main(Congratulations)
    {
      int i;
      for(LinuxWolf; i <= 34; i++)
      {
         printf("%d ", "Happy Birthday!!!");
      }
      for(i=1; i <= 34; i++)
      {
         printf("%d ", Best wishes, health, happiness, love and career success!);
      }
      return 0;
    }


    Image
    DoomJedi
    User avatar
    Administrator
     
    Posts: 12720
    Location: Israel

        

    Postby Ron 14 Mar 2016, 20:10

    Happy birthday! :)
    Ron
    User avatar

     
    Posts: 5999

        

    Postby linuxwolf 14 Mar 2016, 23:53

    Thanks guys!! :D >--I

    Nice Birthday programming Jedi. :wink:
    linuxwolf
    User avatar

     
    Posts: 4880
    Location: Australia

        

    Postby DoomJedi 15 Mar 2016, 00:01

    You're welcome, pal :D :D :D
    DoomJedi
    User avatar
    Administrator
     
    Posts: 12720
    Location: Israel

        

    Postby linuxwolf 15 Mar 2016, 12:56

    :D

    Code: Select all
    #include <algorithm>
    #include <iostream>
    #include <vector>

    namespace Sfx
    {
       enum e
       {
          extinguished,
          blow,
       };

       void play(enum e x)
       {
          std::cout << "sound effect: " << x << std::endl;
       }
    };

    class Candle
    {
    public:
       typedef std::vector<Candle> Vec;

       bool burning;

       Candle() : burning(true)
       {
       }

       void extinguish(void)
       {
          if (burning)
          {
             Sfx::play(Sfx::extinguished);
             burning = false;
          }
       }
    };

    typedef Candle::Vec Cake;

    void extinguishCandle(Candle &candle)
    {
       candle.extinguish();
    }

    class LinuxWolf
    {
    public:
       int age;

       LinuxWolf() : age(34)
       {
       }

       void blow(Cake &cake)
       {
          Sfx::play(Sfx::blow);
          std::for_each(cake.begin(), cake.end(), extinguishCandle);
       }
    };

    int main(int argc, char **argv)
    {
       LinuxWolf linuxWolf;

       Cake cake(linuxWolf.age);

       linuxWolf.blow(cake);

       const std::string s("I'm glad you handled the candles");
       return std::accumulate(s.begin(), s.end(), 0);
    }
    linuxwolf
    User avatar

     
    Posts: 4880
    Location: Australia

        

    Postby DoomJedi 15 Mar 2016, 13:13

    Return "I'm glad you handled the candles" :)
    DoomJedi
    User avatar
    Administrator
     
    Posts: 12720
    Location: Israel

        

    Postby DoomJedi 23 May 2016, 09:37

    Happy Birthday, pwojo588 ! }8O--
    >--I >--I
    DoomJedi
    User avatar
    Administrator
     
    Posts: 12720
    Location: Israel

        

    PreviousNext

    Return to General topics


    Who is online

    Users browsing this forum: No registered users and 1 guest

    cron