I failed to code a variation of buzzfizz in an interview today

i failed to code a variation of buzzfizz in an interview today

share the question

>buzzfizz

...after all the time you spent in Sup Forums?

WTF is wrong with you?

haha. no jerb for you. back to the pile brainlet.

kys you'reself self famalam

this

>after all the time
>not because of it

OP probably sperged out and ended up writing something that was a mix of assembly, C, and Haskell, and not correct in any of them.

Just popped open the console and this worked first try

new Array(100).fill(0).map((item,i)=>i%3===0&&i%5===0&&i!==0?'fizzbuzz':(i%3===0&&i!==0?'fizz':(i%5===0&&i!==0?'buzz':i)))

what god-awful language is this

JavaScript dummy. If you knew anything about programming you'd recognize that.

This is definitely the sperg way to write FizzBuzz. 2/10.

I didn't write it, reply to not me.

Array(100).fill().map((x,i) => ++i % 15 ? i % 3 ? i % 5 ? i : 'buzz' : 'fizz' : 'fizzbuzz')

shorter
Array(100).fill().map((x,i) => ((++i % 3 ? '' : 'Fizz') + (i % 5 ? '' : 'Buzz')) || i)

I have always read about that thing here but never bothered to learn what it is. I just looked it up and it's incredibly trivial, even I that just learned basic programming in high school instantly knew how to do it (and the example on Wikipedia confirmed that I was right). If you are looking for a programming job and you couldn't figure out in the blink of an eye, I am not even gonna insult you because you're a poor sad bastard that deserves everyone's pity.

You just reminded me of why I never bothered to learn java anything..

It's FizzBuzz not buzzfizz.. Sheesh! Honestly user, if you failed at FizzBuzz you probably are not good enough yet to code for a living. Keep honing your skills.. It takes years of practice.

le ebin one line coding

>not using java

Could be way worse. OP could have spent the entire time trying to describe Fizz and Buzz using the calculus of constructions in Coq, or making a program specification in Atelier B. Or, even worse, tried to write in in Brainfuck for style points.

You're literally fucking retarded, though. Once you understand all the paradigms, it takes like a day or two to "learn" a language. Just because you don't want to use either, there's no reason to not know what two of the most widely used languages in the industry even fuckin' look like just because you wanna be a hipster.

Btw that was js written like scheme, and if you don't recognize scheme OR js OR java then just go kill yourself.

Fuck off, pajeet.

Hey guys, it's the guy that didn't know what fizzbuzz is, trying to give advice on how to find a programming job. Enjoy your tendies and good boy points. Playing Dwarf Fortress all day doesn't make you a programmer, you fuckin' NEET.

Java is on 3 billion devices, if you're not learning it you're a fool

>knowing some cliche HR bit of nothing is more important to landing a software job than ability to program
Yeah, not baiting anyone with that.

If you failed anything that can be compared to fizzbuzz then you are not read for a job in programming. And, frankly, you should brush up on your Elementary School math.

I never said I don't know Java, just that it's literally never what I go to for any of my projects. If my job was app development, well sure, I'd use Java all the time... begrudgingly. I think it's a bloated piece of shit, personally. Then again, most of what I do is back-end and infosec, and in my spare time I contribute language libraries to shit like Idris and OCaml. Anyway, fuck off, pajeet, go put the poo in the loo you fuckin' library-googling brainlet.

This
Hurry up OP

Hey, it's the guy that's trying to cover up the fact that he's never gone to any interview, calling one of the most common interview questions - which he apparently hadn't heard of before this thread - cliche. Rope yourself, you fucking piece of shit. If you don't get the point of asking interview applicants to write a fizzbuzz for low-level coding jobs, then you've clearly never worked in the industry. Wanna prove me wrong and post your github, you fucking LARPer?

Yeah but that's basically functional style Javascript. Most Javascript is written in an imperative/event-oriented style.

Yeah apparently a lot of people just don't know what a modulus operator is, and end up trying to write their own functions to find the remainder, usually with loops or something.

Yeah except that style of Javascript is a lot more like haskal or scheme than actual Java. The Java solution would look like
import Java.lang.fizzbuzz;

public class FizzbuzzApp {
public static void main(String[] args) {
FizzbuzzServiceProvider fsp = new FizzbuzzServiceProvider(System.out);
fsp.doFizzBuzz(1, 100);
return 0;
}
}

>that java solution
>mysides.kek

you're not wrong though

Tbqh for a lot of programming jobs that do a fizzbuzz test during the interview, something similar to this would be exactly what they're looking for.

"You want me to do what? Ok, sure, let me google around a second for the library. Ah, got it. Here you go."

Writing it from the ground up would make you look like a cs101 student or a failed nerd

congratulations, you're completely unqualified to be a programmer

Hey guys, OP here. Quit being mean to me, you nerds! No wonder women are underrepresented in tech. I'm just as qualified as any one of you fat loser neckbeard virgins!!!

Fucking hell. See those numbers on the right of the screen in the bar with return, catalog, etc before all the posts? The third number tells you how many unique posters are ITT.

ITT: 22 people who assume that anyone who disagrees with any single one of their posts are the same user. Fuck off and die, you solipsistic little pieces of shit.

>NYEEHH but YOU'RE wrong because you said THIS over HERE!!! (link to a post by someone completely different).

No wonder the "there's only one person on Sup Forums" meme became a thing. Get your heads out of your asses, you autists. Just because you only deal with one other person who disagrees with you IRL (you mom) doesn't mean that everyone else who responds to you is the same person.

Also ITT: Children who think that not knowing about something makes you cool or elite.

Am I doing this right guize

dear god just stop

open eclipse and do it right

Fucking nailed it! In the best language ever, too!

>one of the most common interview questions

I've literally never been asked FizzBuzz in an interview. I was always asked way harder questions, even for internship gigs. If a company asked me to do FizzBuzz I'd probably be wary of working for them as it would just come across as being so outside the norm for a software company.

You're a woman? Why didn't you say so?

Where do you even get VB5?

>eclipse

Pirated it, obviously
It's basically identical to 6 except that the runtime for 5 is not included in recent windows versions by default and the help system isn't bloated

Paradigms blah blah you're a fucking noob and I can prove it. You know java! The most over hyped language on the planet.

No one wanted to use this shitty language because the syntax sucks like your mother, and it had (still has) all kinds of security loopholes that they have had to fix over the years.

If it weren't for all the money they spent on hyping this shitty language, literally no one would be using it.

One more thing.. One line wonders is the hallmark of a noob programmer because you think it's cool and you think it makes you look smart..

Maybe to other noobs, but not to people who have were writing code even before you were born.

this cheeky cunt

Agreed and much more readable than the one line wonder the noob wrote. But I still think something like C++ just makes more sense. I really don't like java syntax.

>I haven't been asked to fizzbuzz at any of the 10 interviews I've gone to, which means nobody else has ever!

Grow up.

Nice strawman, there. Way to deflect away from how you couldn't recognize one of the most widely used languages on the planet, while also claiming that it sucks. You should at least learn a language before you talk shit about it, retard.

>i'm a noob
Tell that to my bank account, faggot.

I probably know how to jack a guy off, too, but it doesn't mean that I go out of my way to do it. Not knowing something doesn't make you cool. You're calling me a dumbass for using a language that's the standard for Android development. You probably don't even have a job, you fuckin' NEET, at least not one in tech.
And guess what, I hate Java, too. At my job, for most projects I'm using either Erlang, OCaml, Haskell, or Matlab. Doesn't mean it's dumb that I spent the time to, you know, learn as much about every widely used language as possible, you brainlet.

>paradigms blah blah
Says the guy who can't code.