Our rules have been updated and given their own forum. Go and look at them! They are nice, and there may be new ones that you didn't know about! Hooray for rules! Hooray for The System! Hooray for Conforming!
Our new Indie Games subforum is now open for business in G&T. Go and check it out, you might land a code for a free game. If you're developing an indie game and want to post about it, follow these directions. If you don't, he'll break your legs! Hahaha! Seriously though.

North Country [chat]land

16768707273100

Posts

  • bowenbowen Registered User regular
    That solution for isEven is overly verbose even, but I leave it that way for the sake of clarity, you could just do something like:

    return !(Number % 2);
  • Irond WillIrond Will Super Moderator, Moderator mod
    bowen wrote: »
    kaleedity wrote: »
    kaleedity wrote: »
    I hadn't heard of fizzbuzz, but I'm glad I was actually capable of solving it quickly

    I don't get to do much programming or even scripting nowadays
    The thing is it is like the most basic test of ability.

    Like getting an artist to draw a cube with perspective.

    And so many people fail. I watched so many terrible interviews. We used to put the most spectacular failed tests up on a wall.

    my brother's first boss fired people that didn't use his code

    he had a 30-40 line function to determine whether or not a number was even or odd

    it was hard to not get fired
    bool isEven(int Number)
    {
        return Number % 2 == 0;
    }
    

    Yeah, that'd be real hard, actually, I'd lose my mind within a week.

    ftfy
  • Evil MultifariousEvil Multifarious Registered User regular
    Echo wrote: »
    Fizzbuzz is a "classic" interview question (that nobody actually gets exposed to in real life). It goes like this:

    Count from 1 to 100. If the number is divisible by 3, print "fizz" instead of the number. If divisible by 5, print "buzz" instead. If divisible by 3 and 5, print "fizzbuzz".

    It's pretty much a "weed out the impostors" question.

    I don't program, but the stumbling block for me would be whatever determines a number's divisibility

    I guess you'd have to know how to make the program identify integers
  • shalmeloshalmelo sees no evil Registered User regular
    Organichu wrote: »
    also being in the car of an awful driver is terrifying

    jesus

    that was a stressful trip to south philly

    God, yes.

    For the first few years after I moved to Seattle I didn't have a car. So when I was dating I would typically get a ride from the girl I was seeing. I broke off two promising relationships with women I liked because I was just too afraid to be a passenger when they were driving.

    Steam ID: Shalmelo || LoL: melo2boogaloo || tweets
  • bowenbowen Registered User regular
    When everyone eats shit, sometimes you have to eat shit to fit in.

    The whole time I was learning PHP I was like this isn't a real language. It's so unprofessional

    I am worried unprofessional in this regard might mean the mixing of HTML and PHP code to complete your web markup.

    PHP is about as good as perl, asp, and c/c++ in this regards. You can write really nice code in php, actually!

    Vanilla's source code is a testament to that.

  • DelmainDelmain Registered User regular
    Wizard is almost more about the damage than control in Neverwinter. None of the classes really control that much.
    Torak - Elcor Vanguard
  • CindersCinders Registered User regular
    Shivahn wrote: »
    Cinders wrote: »
    Shivahn, what class will you be rolling in Neverwinter?

    I've got a Control Wizard or whatever it's called.

    She's been made but hasn't entered the world yet.

    I am all about the debuffs and subtle things, so it seems perfect for me. I am not a super actiony person, I am a "do weird shit and stuff to them" person. Like most RPGs piss me off because poisoning your opponent and applying debuffs doesn't work on bosses.

    So yeah, control wizard.

    It's a fun playstyle.

    It's why I loved the Mesmer in Guild Wars.
  • Shazkar ShadowstormShazkar Shadowstorm Registered User regular
    there's this food thing with a bunch of food stands

    and it wasnt raining when i went there

    and it started pouring while waiting for my food

    so everything from my calves down is soaked

    hm
    | Steam & XBL: Shazkar |
  • bowenbowen Registered User regular
    Irond Will wrote: »
    bowen wrote: »
    kaleedity wrote: »
    kaleedity wrote: »
    I hadn't heard of fizzbuzz, but I'm glad I was actually capable of solving it quickly

    I don't get to do much programming or even scripting nowadays
    The thing is it is like the most basic test of ability.

    Like getting an artist to draw a cube with perspective.

    And so many people fail. I watched so many terrible interviews. We used to put the most spectacular failed tests up on a wall.

    my brother's first boss fired people that didn't use his code

    he had a 30-40 line function to determine whether or not a number was even or odd

    it was hard to not get fired
    bool isEven(int Number)
    {
        return Number % 2 == 0;
    }
    

    Yeah, that'd be real hard, actually, I'd lose my mind within a week.

    ftfy

    I BEAT YOU TO WHY I DID THAT
  • CindersCinders Registered User regular
    Can't decide between a cleric or the two handed warrior.
  • bowenbowen Registered User regular
    I'll start writing all my future code as one line for loops, even when for loops are unnecessary.
  • KageraKagera Registered User regular
    bowen wrote: »
    kaleedity wrote: »
    kaleedity wrote: »
    I hadn't heard of fizzbuzz, but I'm glad I was actually capable of solving it quickly

    I don't get to do much programming or even scripting nowadays
    The thing is it is like the most basic test of ability.

    Like getting an artist to draw a cube with perspective.

    And so many people fail. I watched so many terrible interviews. We used to put the most spectacular failed tests up on a wall.

    my brother's first boss fired people that didn't use his code

    he had a 30-40 line function to determine whether or not a number was even or odd

    it was hard to not get fired
    bool isEven(int Number)
    {
        return Number % 2 == 0 ? true : false;
    }
    

    Yeah, that'd be real hard, actually, I'd lose my mind within a week.

    How would you turn that into 30 or 40 lines? Was he coding in ones and Zeroes?
    _J_ wrote:
    If we only allowed pedophiles to be parents, then we would never have to worry about children being left alone, unwatched.
    XBL: Fanatical One AIM: itskagera
  • WinkyWinky Registered User regular
    Echo wrote: »
    Fizzbuzz is a "classic" interview question (that nobody actually gets exposed to in real life). It goes like this:

    Count from 1 to 100. If the number is divisible by 3, print "fizz" instead of the number. If divisible by 5, print "buzz" instead. If divisible by 3 and 5, print "fizzbuzz".

    It's pretty much a "weed out the impostors" question.

    I don't program, but the stumbling block for me would be whatever determines a number's divisibility

    I guess you'd have to know how to make the program identify integers

    Luckily, in programming you have a type that is only possibly an integer.

    Actually, how about a function that finds out if a double is even? I don't even know how % usually works with doubles.
    vspgsp.jpg
  • CouscousCouscous Registered User regular
    Cinders wrote: »
    Can't decide between a cleric or the two handed warrior.

    Two handed warrior sucks.
  • ShivahnShivahn Registered User regular
    Echo wrote: »
    Fizzbuzz is a "classic" interview question (that nobody actually gets exposed to in real life). It goes like this:

    Count from 1 to 100. If the number is divisible by 3, print "fizz" instead of the number. If divisible by 5, print "buzz" instead. If divisible by 3 and 5, print "fizzbuzz".

    It's pretty much a "weed out the impostors" question.

    I don't program, but the stumbling block for me would be whatever determines a number's divisibility

    I guess you'd have to know how to make the program identify integers

    Most languages let you take the modulus (remainder after division) in a simple instruction.

    So it's easy to just go "if divisible by three, do this, if by five, do this" by seeing if the number modulo 3 or 5 is zero.
  • ShivahnShivahn Registered User regular
    Delmain wrote: »
    Wizard is almost more about the damage than control in Neverwinter. None of the classes really control that much.

    WELL WHATEVER I LOVE WIZARDS ANYWAY
  • syndalissyndalis Aballah Can Tah Advancing the Human ConditionRegistered User regular
    And of course it's raining like crazy now that I am a mile from home and no umbrella and an iPhone on me.

    Mother Nature can eat a bag of dicks.


    Fak U @Shazkar Sahdowstorm
    meat.jpg
  • Irond WillIrond Will Super Moderator, Moderator mod
    Echo wrote: »
    Fizzbuzz is a "classic" interview question (that nobody actually gets exposed to in real life). It goes like this:

    Count from 1 to 100. If the number is divisible by 3, print "fizz" instead of the number. If divisible by 5, print "buzz" instead. If divisible by 3 and 5, print "fizzbuzz".

    It's pretty much a "weed out the impostors" question.

    I don't program, but the stumbling block for me would be whatever determines a number's divisibility

    I guess you'd have to know how to make the program identify integers

    the easiest way is the modulo function, which essentially yeilds the remainder after integer division.
  • kaleeditykaleedity bad biscuits make the baker broke bro Registered User regular
    the 30-40 line thing was mainly because it started out trying to do something else

    but it eventually only determined whether or not something was even or odd

    also the guy had no idea what mod was
  • CindersCinders Registered User regular
    Couscous wrote: »
    Cinders wrote: »
    Can't decide between a cleric or the two handed warrior.

    Two handed warrior sucks.

    Aw, I thought it was just the tanky warrior that was unfun.
  • ShivahnShivahn Registered User regular
    Cinders wrote: »
    Shivahn wrote: »
    Cinders wrote: »
    Shivahn, what class will you be rolling in Neverwinter?

    I've got a Control Wizard or whatever it's called.

    She's been made but hasn't entered the world yet.

    I am all about the debuffs and subtle things, so it seems perfect for me. I am not a super actiony person, I am a "do weird shit and stuff to them" person. Like most RPGs piss me off because poisoning your opponent and applying debuffs doesn't work on bosses.

    So yeah, control wizard.

    It's a fun playstyle.

    It's why I loved the Mesmer in Guild Wars.

    I played a Warlock in WoW and it was great for me.
  • DelmainDelmain Registered User regular
    Winky wrote: »
    Echo wrote: »
    Fizzbuzz is a "classic" interview question (that nobody actually gets exposed to in real life). It goes like this:

    Count from 1 to 100. If the number is divisible by 3, print "fizz" instead of the number. If divisible by 5, print "buzz" instead. If divisible by 3 and 5, print "fizzbuzz".

    It's pretty much a "weed out the impostors" question.

    I don't program, but the stumbling block for me would be whatever determines a number's divisibility

    I guess you'd have to know how to make the program identify integers

    Luckily, in programming you have a type that is only possibly an integer.

    Actually, how about a function that finds out if a double is even? I don't even know how % usually works with doubles.

    double d = Math.pi;
    int i = (int) d;
    Torak - Elcor Vanguard
  • kaleeditykaleedity bad biscuits make the baker broke bro Registered User regular
    gonna make the 2h warrior work fuck the haters
  • AManFromEarthAManFromEarth Their ideas are old and their ideas are bad. Risk is our business.Registered User regular
    eO5sjqOl.jpg
    Lh96QHG.png
  • bowenbowen Registered User regular
    You could probably convert a modulus even/odd check into 40 lines of code if you were doing bit masking or assembly or something. Man that'd be hard as fuck to do on purpose though.
  • BeNarwhalBeNarwhal The Gatekeeper of D&D [chat] Toronto, CanadaRegistered User regular
    New glasses have arrived!

    Photoshoot later today, probably. :P

    They got here suspiciously fast, though.

    #TheFutureIsScary #GlassesAreFancyAndTakeMoreTimeThanThisISwear #MultipleHashtagsOnEveryPost
  • DelmainDelmain Registered User regular
    bowen wrote: »
    You could probably convert a modulus even/odd check into 40 lines of code if you were doing bit masking or assembly or something. Man that'd be hard as fuck to do on purpose though.

    Yeah, I don't know how you get to 40 lines, even in Assembly.
    Torak - Elcor Vanguard
  • ThomamelasThomamelas Registered User regular
    Delmain wrote: »
    Wizard is almost more about the damage than control in Neverwinter. None of the classes really control that much.

    Pfft. My Guardian Fighter is all about control. I want mobs to die and they do.
    There's no living with a killing. There's no goin' back from one. Right or wrong, it's a brand... a brand sticks. There's no goin' back. Now you run on home to your mother and tell her... tell her everything's alright. And there aren't any more guns in the valley.
  • bloodyroarxxbloodyroarxx Registered User regular
    Sons of Anarchy is so good
  • descdesc the '87 stick-up kids Registered User regular
    kaleedity wrote: »
    gonna make the 2h warrior work fuck the haters

    Everyone says it sucks but I never die and the game is easy so who knows.

    I haven't really played my rogue more than 10 or 15 minutes because I wanted to save it to level up with cool friends / alts.
  • japanjapan Registered User regular
    I, too, got caught in the rain.

    Fucking monsoon.
  • ShivahnShivahn Registered User regular
    Kagera wrote: »
    bowen wrote: »
    kaleedity wrote: »
    kaleedity wrote: »
    I hadn't heard of fizzbuzz, but I'm glad I was actually capable of solving it quickly

    I don't get to do much programming or even scripting nowadays
    The thing is it is like the most basic test of ability.

    Like getting an artist to draw a cube with perspective.

    And so many people fail. I watched so many terrible interviews. We used to put the most spectacular failed tests up on a wall.

    my brother's first boss fired people that didn't use his code

    he had a 30-40 line function to determine whether or not a number was even or odd

    it was hard to not get fired
    bool isEven(int Number)
    {
        return Number % 2 == 0 ? true : false;
    }
    

    Yeah, that'd be real hard, actually, I'd lose my mind within a week.

    How would you turn that into 30 or 40 lines? Was he coding in ones and Zeroes?

    The most basic basic language could still do it in less than ten.

    Like literal machine code would probably be ten to twenty bytes?

    I've never coded in assembly so I could be totally wrong but I think there's a division instruction which leaves a remainder somewhere, so at worst you'd need to move the variable to somewhere, do the division, move the remainder, compare to zero, then have a jump if greater than instruction for odd and the even code can follow that.

    Or whatever.

    I should learn some assembly.
  • DelmainDelmain Registered User regular
    Yeah, pretty much all the classes are pretty fun.

    Don't roll rogue if you just want to be the highest damage because rogue does like 0 AoE and that's what all the dungeons are about.
    Torak - Elcor Vanguard
  • OrganichuOrganichu Registered User regular
    edited May 2013
    kaleedity wrote: »
    kaleedity wrote: »
    I hadn't heard of fizzbuzz, but I'm glad I was actually capable of solving it quickly

    I don't get to do much programming or even scripting nowadays
    The thing is it is like the most basic test of ability.

    Like getting an artist to draw a cube with perspective.

    And so many people fail. I watched so many terrible interviews. We used to put the most spectacular failed tests up on a wall.

    my brother's first boss fired people that didn't use his code

    he had a 30-40 line function to determine whether or not a number was even or odd

    it was hard to not get fired

    i'm imagining this
    import java.util.*;
    
    public class EvenOrOdd 
    {
        public static void main(String[] args) 
        {
        Scanner input = new Scanner(System.in);
        System.out.println("Please enter a positive integer: ");
        int valueEntered = input.nextInt();
        System.out.println("Your number is " + determineEvenness(valueEntered));
        }
        public static String determineEvenness(int number)
        {
        String evenness = "";    
        if (number == 1)
        {
            evenness = "odd";
        }
        else if (number == 2)
        {
            evenness = "even";
        }
        else if (number == 3)
        {
            evenness = "odd";
        }
        else if (number == 4)
        {
            evenness = "even";
        }
        else if (number == 5)
        {
            evenness = "odd";
        }
        else if (number == 6)
        {
            evenness = "even";
        }
        else if (number == 7)
        {
            evenness = "odd";
        }
        else if (number == 8)
        {
            evenness = "even";
        }
        else if (number == 9)
        {
            evenness = "odd";
        }
        ...
        return evenness;
        }
    }
    
    Organichu on
  • descdesc the '87 stick-up kids Registered User regular
    eO5sjqOl.jpg

    I ...
  • CindersCinders Registered User regular
    Shivahn wrote: »
    Cinders wrote: »
    Shivahn wrote: »
    Cinders wrote: »
    Shivahn, what class will you be rolling in Neverwinter?

    I've got a Control Wizard or whatever it's called.

    She's been made but hasn't entered the world yet.

    I am all about the debuffs and subtle things, so it seems perfect for me. I am not a super actiony person, I am a "do weird shit and stuff to them" person. Like most RPGs piss me off because poisoning your opponent and applying debuffs doesn't work on bosses.

    So yeah, control wizard.

    It's a fun playstyle.

    It's why I loved the Mesmer in Guild Wars.

    I played a Warlock in WoW and it was great for me.

    Yeah, I had a lot of fun playing Warlock too. Just running around dotting everything was very satisfying.

    Plus I loved the little fellhunter.
  • MazzyxMazzyx Changing the World Order. Registered User regular
    Shivahn wrote: »
    Delmain wrote: »
    Wizard is almost more about the damage than control in Neverwinter. None of the classes really control that much.

    WELL WHATEVER I LOVE WIZARDS ANYWAY

    Nah it is about control just not on bosses since they are immune. But controlling adds is huge. I run a force push, force choke, an ice stun and a shield I can use to repel with. Lots of control.
    falasig.png
  • Ravenhpltc24Ravenhpltc24 Registered User regular
    My beautiful Sennheiser headphones that have been through so much are making a weird popping sound when nothing is playing. Don't crack out on me now, we're so close to the graduation payout...
    (V) ( ;,,; ) (V)
  • japanjapan Registered User regular
    Also this "Most Haunted" faux documentary has the weirdest disclaimer.

    "This programme is for entertainment purposes only".

    I suppose that's about as vague as it is possible to make "you know this isn't real, right?"
  • bowenbowen Registered User regular
    Fucking java.

    :rotate:
This discussion has been closed.