Skip to main content

All Questions

Filter by
Sorted by
Tagged with
8 votes
3 answers
33k views

If statements vs switch cases? in a JavaScript game and if to use a function [duplicate]

I am developing a game in JavaScript where you start with a user input, stored in the variable "controller". The options for the user consists of start to start the game or about to learn about the ...
Ben Watkins's user avatar
26 votes
5 answers
27k views

Multiple arguments in function call vs single array

I have a function that takes in a set of parameters, then applies to them as conditions to an SQL query. However, while I favored a single argument array containing the conditions themselves: ...
xiankai's user avatar
  • 383