Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Other Discussions
  3. The Weird and The Wonderful
  4. Programming Hell

Programming Hell

Scheduled Pinned Locked Moved The Weird and The Wonderful
jsonquestionannouncement
8 Posts 7 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    Affan Saied
    wrote on last edited by
    #1

    I've been thinking lately about religion, it's something I don't understand and unfortunately(it really is unfortunate at some times) "God" gave me a brain to analyse, think and come to my own conclusions, not the ones written in "holy" books which have been edited/rewritten so many times by powerful people throughout history, let's not forget that not so long ago tickets to heaven were being sold(i guess they ran out of space nowadays :P )... I consider anyone who follows anything blindly to be a fool, we have a brain and we should use it... Just because your parents, priests, friends, news, tv (so on...) say something, it doesn't make it true, they, just as anyone else, are human and can be wrong... Now that I got that off my chest, I was wondering how hell would look like from a programming perspective. I Googled hell, and ended up going into wikipedia, from which I quote "Revelation 20:10 (NIV) illustrates Hell as a "lake with burning sulfure" " From this information, I see that there will be a lot of burning involved, therefore as a good programming habit, I create a method and call it "burn", the method is unclear, should it return anything? does it take any arguments? is it static(as in, a part of hell)? Lets simplify for now and say public void burn() Now I'm curious about a way out, I read a bit more in wikipedia and found out that in Christianity, I quote "As opposed to the concept of Purgatory, damnation to Hell is considered final and irreversible". Wow, that must suck! Islam, I quote "The Qur'an also says that some of those who are damned to hell are not damned forever, but instead for an indefinite period of time" Hehe and all this time I thought that Christiniaty was about forgiveness... Chinese and Japanese religions, I quote "The Chinese depiction of Hell doesn't necessarily mean a long time suffering for those who enter Hell, nor does it mean that person is bad. The Chinese view Hell as similar to a present day passport or immigration control station. In a Chinese funeral, they burn many Hell Bank Notes for the dead. With this Hell money, the dead person can bribe the ruler of Hell, and spend the rest of the money either in Hell or in Heaven." HAHAHAHAHAHAHAHA i looooooooove this!!! In short, our main program should be like this, Christianity, its an infinite loop, there's no way out! therefore: while(true) { burn(); } Islam, we need to specify a condition, since there "might" be a way out, therefore: boolean forgiven = false; while(forgiven

    _ A F B M 5 Replies Last reply
    0
    • A Affan Saied

      I've been thinking lately about religion, it's something I don't understand and unfortunately(it really is unfortunate at some times) "God" gave me a brain to analyse, think and come to my own conclusions, not the ones written in "holy" books which have been edited/rewritten so many times by powerful people throughout history, let's not forget that not so long ago tickets to heaven were being sold(i guess they ran out of space nowadays :P )... I consider anyone who follows anything blindly to be a fool, we have a brain and we should use it... Just because your parents, priests, friends, news, tv (so on...) say something, it doesn't make it true, they, just as anyone else, are human and can be wrong... Now that I got that off my chest, I was wondering how hell would look like from a programming perspective. I Googled hell, and ended up going into wikipedia, from which I quote "Revelation 20:10 (NIV) illustrates Hell as a "lake with burning sulfure" " From this information, I see that there will be a lot of burning involved, therefore as a good programming habit, I create a method and call it "burn", the method is unclear, should it return anything? does it take any arguments? is it static(as in, a part of hell)? Lets simplify for now and say public void burn() Now I'm curious about a way out, I read a bit more in wikipedia and found out that in Christianity, I quote "As opposed to the concept of Purgatory, damnation to Hell is considered final and irreversible". Wow, that must suck! Islam, I quote "The Qur'an also says that some of those who are damned to hell are not damned forever, but instead for an indefinite period of time" Hehe and all this time I thought that Christiniaty was about forgiveness... Chinese and Japanese religions, I quote "The Chinese depiction of Hell doesn't necessarily mean a long time suffering for those who enter Hell, nor does it mean that person is bad. The Chinese view Hell as similar to a present day passport or immigration control station. In a Chinese funeral, they burn many Hell Bank Notes for the dead. With this Hell money, the dead person can bribe the ruler of Hell, and spend the rest of the money either in Hell or in Heaven." HAHAHAHAHAHAHAHA i looooooooove this!!! In short, our main program should be like this, Christianity, its an infinite loop, there's no way out! therefore: while(true) { burn(); } Islam, we need to specify a condition, since there "might" be a way out, therefore: boolean forgiven = false; while(forgiven

      _ Offline
      _ Offline
      _Erik_
      wrote on last edited by
      #2

      Since there is more than one religion which states that you'll get to hell if you are not member of it, and there is more than one which states that you'll never get out of hell once you have entered it, I guess we can simplify the implementation a lot:

      1 Reply Last reply
      0
      • A Affan Saied

        I've been thinking lately about religion, it's something I don't understand and unfortunately(it really is unfortunate at some times) "God" gave me a brain to analyse, think and come to my own conclusions, not the ones written in "holy" books which have been edited/rewritten so many times by powerful people throughout history, let's not forget that not so long ago tickets to heaven were being sold(i guess they ran out of space nowadays :P )... I consider anyone who follows anything blindly to be a fool, we have a brain and we should use it... Just because your parents, priests, friends, news, tv (so on...) say something, it doesn't make it true, they, just as anyone else, are human and can be wrong... Now that I got that off my chest, I was wondering how hell would look like from a programming perspective. I Googled hell, and ended up going into wikipedia, from which I quote "Revelation 20:10 (NIV) illustrates Hell as a "lake with burning sulfure" " From this information, I see that there will be a lot of burning involved, therefore as a good programming habit, I create a method and call it "burn", the method is unclear, should it return anything? does it take any arguments? is it static(as in, a part of hell)? Lets simplify for now and say public void burn() Now I'm curious about a way out, I read a bit more in wikipedia and found out that in Christianity, I quote "As opposed to the concept of Purgatory, damnation to Hell is considered final and irreversible". Wow, that must suck! Islam, I quote "The Qur'an also says that some of those who are damned to hell are not damned forever, but instead for an indefinite period of time" Hehe and all this time I thought that Christiniaty was about forgiveness... Chinese and Japanese religions, I quote "The Chinese depiction of Hell doesn't necessarily mean a long time suffering for those who enter Hell, nor does it mean that person is bad. The Chinese view Hell as similar to a present day passport or immigration control station. In a Chinese funeral, they burn many Hell Bank Notes for the dead. With this Hell money, the dead person can bribe the ruler of Hell, and spend the rest of the money either in Hell or in Heaven." HAHAHAHAHAHAHAHA i looooooooove this!!! In short, our main program should be like this, Christianity, its an infinite loop, there's no way out! therefore: while(true) { burn(); } Islam, we need to specify a condition, since there "might" be a way out, therefore: boolean forgiven = false; while(forgiven

        A Offline
        A Offline
        AspDotNetDev
        wrote on last edited by
        #3

        TLDR. And spiff that up with some PRE code blocks why don't ya.

        [WikiLeaks Cablegate Cables]

        1 Reply Last reply
        0
        • A Affan Saied

          I've been thinking lately about religion, it's something I don't understand and unfortunately(it really is unfortunate at some times) "God" gave me a brain to analyse, think and come to my own conclusions, not the ones written in "holy" books which have been edited/rewritten so many times by powerful people throughout history, let's not forget that not so long ago tickets to heaven were being sold(i guess they ran out of space nowadays :P )... I consider anyone who follows anything blindly to be a fool, we have a brain and we should use it... Just because your parents, priests, friends, news, tv (so on...) say something, it doesn't make it true, they, just as anyone else, are human and can be wrong... Now that I got that off my chest, I was wondering how hell would look like from a programming perspective. I Googled hell, and ended up going into wikipedia, from which I quote "Revelation 20:10 (NIV) illustrates Hell as a "lake with burning sulfure" " From this information, I see that there will be a lot of burning involved, therefore as a good programming habit, I create a method and call it "burn", the method is unclear, should it return anything? does it take any arguments? is it static(as in, a part of hell)? Lets simplify for now and say public void burn() Now I'm curious about a way out, I read a bit more in wikipedia and found out that in Christianity, I quote "As opposed to the concept of Purgatory, damnation to Hell is considered final and irreversible". Wow, that must suck! Islam, I quote "The Qur'an also says that some of those who are damned to hell are not damned forever, but instead for an indefinite period of time" Hehe and all this time I thought that Christiniaty was about forgiveness... Chinese and Japanese religions, I quote "The Chinese depiction of Hell doesn't necessarily mean a long time suffering for those who enter Hell, nor does it mean that person is bad. The Chinese view Hell as similar to a present day passport or immigration control station. In a Chinese funeral, they burn many Hell Bank Notes for the dead. With this Hell money, the dead person can bribe the ruler of Hell, and spend the rest of the money either in Hell or in Heaven." HAHAHAHAHAHAHAHA i looooooooove this!!! In short, our main program should be like this, Christianity, its an infinite loop, there's no way out! therefore: while(true) { burn(); } Islam, we need to specify a condition, since there "might" be a way out, therefore: boolean forgiven = false; while(forgiven

          F Offline
          F Offline
          fjdiewornncalwe
          wrote on last edited by
          #4

          I suppose that's why overloads and inheritance come into play since most religions just override and modify the behavior of ones that came before.

          I wasn't, now I am, then I won't be anymore.

          F 1 Reply Last reply
          0
          • A Affan Saied

            I've been thinking lately about religion, it's something I don't understand and unfortunately(it really is unfortunate at some times) "God" gave me a brain to analyse, think and come to my own conclusions, not the ones written in "holy" books which have been edited/rewritten so many times by powerful people throughout history, let's not forget that not so long ago tickets to heaven were being sold(i guess they ran out of space nowadays :P )... I consider anyone who follows anything blindly to be a fool, we have a brain and we should use it... Just because your parents, priests, friends, news, tv (so on...) say something, it doesn't make it true, they, just as anyone else, are human and can be wrong... Now that I got that off my chest, I was wondering how hell would look like from a programming perspective. I Googled hell, and ended up going into wikipedia, from which I quote "Revelation 20:10 (NIV) illustrates Hell as a "lake with burning sulfure" " From this information, I see that there will be a lot of burning involved, therefore as a good programming habit, I create a method and call it "burn", the method is unclear, should it return anything? does it take any arguments? is it static(as in, a part of hell)? Lets simplify for now and say public void burn() Now I'm curious about a way out, I read a bit more in wikipedia and found out that in Christianity, I quote "As opposed to the concept of Purgatory, damnation to Hell is considered final and irreversible". Wow, that must suck! Islam, I quote "The Qur'an also says that some of those who are damned to hell are not damned forever, but instead for an indefinite period of time" Hehe and all this time I thought that Christiniaty was about forgiveness... Chinese and Japanese religions, I quote "The Chinese depiction of Hell doesn't necessarily mean a long time suffering for those who enter Hell, nor does it mean that person is bad. The Chinese view Hell as similar to a present day passport or immigration control station. In a Chinese funeral, they burn many Hell Bank Notes for the dead. With this Hell money, the dead person can bribe the ruler of Hell, and spend the rest of the money either in Hell or in Heaven." HAHAHAHAHAHAHAHA i looooooooove this!!! In short, our main program should be like this, Christianity, its an infinite loop, there's no way out! therefore: while(true) { burn(); } Islam, we need to specify a condition, since there "might" be a way out, therefore: boolean forgiven = false; while(forgiven

            B Offline
            B Offline
            Bernhard Hiller
            wrote on last edited by
            #5

            You should add some object-oriented design. Let us start with a HellType enumeration:

            public enum HellType
            {
            Christian,
            Muslim,
            Chinese
            }

            Then we need an interface for the Hell:

            public interface IHell
            {
            HellType HellType { get; }
            //some more useful properties and methods
            }

            Here, some methods should be declared for taking up, treating and removing sinners. Perhaps we could also be interested in the Hell Staff (the devil and his helpers), a list of sinners already in hell, etc. Capacity is not a useful property, as it is always infinite. Now we can come to a more important part: the HellFactory.

            public class HellFactory
            {
            public IHell CreateHell(HellType hellType)
            {
            //create the appropriate hell
            }
            }

            And here, theological problems arise. In all religions, there is only one instance of hell. Hence we must amend the interface with

            IHell Instance { get; }

            and also change our HellFactory

            public IHell GetHell(HellType hellType)
            {
                //get the instance of the appropriate hell
            }
            

            We could also need a static constructor in some hells, as that hell does simply exist. Things become even worse when the only instance has to be created by the apprpriate god... To hell with such a hell!

            L 1 Reply Last reply
            0
            • A Affan Saied

              I've been thinking lately about religion, it's something I don't understand and unfortunately(it really is unfortunate at some times) "God" gave me a brain to analyse, think and come to my own conclusions, not the ones written in "holy" books which have been edited/rewritten so many times by powerful people throughout history, let's not forget that not so long ago tickets to heaven were being sold(i guess they ran out of space nowadays :P )... I consider anyone who follows anything blindly to be a fool, we have a brain and we should use it... Just because your parents, priests, friends, news, tv (so on...) say something, it doesn't make it true, they, just as anyone else, are human and can be wrong... Now that I got that off my chest, I was wondering how hell would look like from a programming perspective. I Googled hell, and ended up going into wikipedia, from which I quote "Revelation 20:10 (NIV) illustrates Hell as a "lake with burning sulfure" " From this information, I see that there will be a lot of burning involved, therefore as a good programming habit, I create a method and call it "burn", the method is unclear, should it return anything? does it take any arguments? is it static(as in, a part of hell)? Lets simplify for now and say public void burn() Now I'm curious about a way out, I read a bit more in wikipedia and found out that in Christianity, I quote "As opposed to the concept of Purgatory, damnation to Hell is considered final and irreversible". Wow, that must suck! Islam, I quote "The Qur'an also says that some of those who are damned to hell are not damned forever, but instead for an indefinite period of time" Hehe and all this time I thought that Christiniaty was about forgiveness... Chinese and Japanese religions, I quote "The Chinese depiction of Hell doesn't necessarily mean a long time suffering for those who enter Hell, nor does it mean that person is bad. The Chinese view Hell as similar to a present day passport or immigration control station. In a Chinese funeral, they burn many Hell Bank Notes for the dead. With this Hell money, the dead person can bribe the ruler of Hell, and spend the rest of the money either in Hell or in Heaven." HAHAHAHAHAHAHAHA i looooooooove this!!! In short, our main program should be like this, Christianity, its an infinite loop, there's no way out! therefore: while(true) { burn(); } Islam, we need to specify a condition, since there "might" be a way out, therefore: boolean forgiven = false; while(forgiven

              M Offline
              M Offline
              Michael Agroskin
              wrote on last edited by
              #6

              Do not believe in anything simply because you have heard it. Do not believe in anything simply because it is spoken and rumored by many. Do not believe in anything simply because it is found written in your religious books. Do not believe in anything merely on the authority of your teachers and elders. Do not believe in traditions because they have been handed down for many generations. But after observation and analysis, when you find that anything agrees with reason and is conducive to the good and benefit of one and all, then accept it and live up to it. The Buddha

              1 Reply Last reply
              0
              • F fjdiewornncalwe

                I suppose that's why overloads and inheritance come into play since most religions just override and modify the behavior of ones that came before.

                I wasn't, now I am, then I won't be anymore.

                F Offline
                F Offline
                fjdiewornncalwe
                wrote on last edited by
                #7

                Really... A univote for that without any comment. That's just cheesy.

                I wasn't, now I am, then I won't be anymore.

                1 Reply Last reply
                0
                • B Bernhard Hiller

                  You should add some object-oriented design. Let us start with a HellType enumeration:

                  public enum HellType
                  {
                  Christian,
                  Muslim,
                  Chinese
                  }

                  Then we need an interface for the Hell:

                  public interface IHell
                  {
                  HellType HellType { get; }
                  //some more useful properties and methods
                  }

                  Here, some methods should be declared for taking up, treating and removing sinners. Perhaps we could also be interested in the Hell Staff (the devil and his helpers), a list of sinners already in hell, etc. Capacity is not a useful property, as it is always infinite. Now we can come to a more important part: the HellFactory.

                  public class HellFactory
                  {
                  public IHell CreateHell(HellType hellType)
                  {
                  //create the appropriate hell
                  }
                  }

                  And here, theological problems arise. In all religions, there is only one instance of hell. Hence we must amend the interface with

                  IHell Instance { get; }

                  and also change our HellFactory

                  public IHell GetHell(HellType hellType)
                  {
                      //get the instance of the appropriate hell
                  }
                  

                  We could also need a static constructor in some hells, as that hell does simply exist. Things become even worse when the only instance has to be created by the apprpriate god... To hell with such a hell!

                  L Offline
                  L Offline
                  Lost User
                  wrote on last edited by
                  #8

                  And, as this is the hall of shame,

                  GOTO HELL;

                  ___________________________________________ .\\axxx (That's an 'M')

                  1 Reply Last reply
                  0
                  Reply
                  • Reply as topic
                  Log in to reply
                  • Oldest to Newest
                  • Newest to Oldest
                  • Most Votes


                  • Login

                  • Don't have an account? Register

                  • Login or register to search.
                  • First post
                    Last post
                  0
                  • Categories
                  • Recent
                  • Tags
                  • Popular
                  • World
                  • Users
                  • Groups