foo (bar)
OR
foo ( bar )
???
Foo (bar)
who cares lul
foo(bar)
kys
foo{ no}
...
//CodeProjects//Guy Manfoo (bar) //Fucked up beyond all repair.{ amoregeneralmethod(bar) //calls a more general method to do something more specific for us. }
if (bar > baz) { foo(bar, bat); fop(bay);}
foo(bar)
Your whitespace fetishism, what purpose does it serve other than requiring more keystrokes?
foo(bar, baz) for better visual separation of arguments and if (x > y) to better distinguish between keywords and functions.
Godking John Carmack uses
foo ( bar )
WHY HAVEN'T YOU ACCEPTED LISP, YOUR SAVIOR, INTO YOU LIFE.
In the beginning, there was nothing. And then God cons'd some cells together and made s-exprs and everything was perfect forever.
Lisp is Jewish terrorism.
Whatever is defined in your language or project guidelines. Alternatively use a good language and justfoo bar
both will do just fine, there are more pressing issues than formatting nitpicks to care about
Sort of agree.
Whatever gets picked and used for a project will do fine, however everyone else should follow instead of forcing their own kind of formatting resulting in the kind of vomit code that is
foo ( bar ) { print "hello";}foo ( bar, foobar ){ // my own code here because i don't follow what has been set}
``` foo bar ```
Of course.
foo(bar );
foo(bar, baz), it's the only way to recognize functions quickly.
i figured the examples shown aren't suitible for an enterprise environment (such as if you are showing your boss different programming styles) so i have taken the liberty of including a well documented library and example program the purpose of displaying such styles
/** * A set of utilitie(s) that extend the functionality of displaying code examples on online imageboards. * * * @author Anonymous > * @version 1.0 * @since 1.0 */public static class MyLib { /** * Calculates foo from bar. * * * @author Anonymous > * @version 1.0 * @since 1.0 * @param bar Your bar goes here. * @return void */ public static pure abstract final int foo(int bar) { // Write your code here }}
then we can call it like this if you want to show foo (bar)
/** * Class for my program that runs the foo() function from MyLib * * * @author Anonymous > * @version 1.0 * @since 1.0 */public static class Program { private static int bar; // bar for use with the foo function. /** * The main entry point of my Java program. * * * @author Anonymous > * @version 1.0 * @since 1.0 * @param args An array of arguments passed to the program by Windows 10. * @return void */ public static void main(String[] args) { bar = 0; // Set bar to 0 MyLib.foo (bar); // Call the function foo with the parametre bar. }}
or like this if you prefer foo(bar)
/** * Class for my program that runs the foo() function from MyLib * * * @author Anonymous > * @version 1.0 * @since 1.0 */public static class Program { private static int bar; // bar for use with the foo function. /** * The main entry point of my Java program. * * * @author Anonymous > * @version 1.0 * @since 1.0 * @param args An array of arguments passed to the program by Windows 10. * @return void */ public static void main(String[] args) { bar = 0; // Set bar to 0 MyLib.foo(bar); // Call the function foo with the parametre bar. }}
Not enough lines of code. It's like you don't even want to get paid.
publicstaticpureabstractfinalintfoo(int bar){ // Write your code here}
i hate java so much
Comments should also be on the line above, to improve readability.
publicstaticpureabstractfinalintfoo(int bar){ // Comments // Code goes here}
bar.foo()
(foo bar)
fboaor
foo( bar )
Am I the only one?
foo ( bar)
foo(
bar)
foo (bar
)
10 FOOBAR
20 GOTO10
Them spaces use up too much memory.
#def foo op
#def bar isafaggot
op(isafaggot)
10FOOBAR20GOTO10
you can make it all on one line for extra LOC optimization!
10 A$ = "FOO"20 B$ = " BAR"30 PRINT A$ B$
It's not all BASIC dialects that let you omit whitespace, but even those who do still need space after line number and a CR before it.
But this would work:
10 FOOBAR:GOTO10
I'm only familiar with Commodore BASIC, a more proper way to write it in C64 BASIC is as follows;
10 DEF FN FOO(BAR)or10DEFFNFOO(BAR)
basically C64 BASIC lets you ignore all whitespace
A thread died for this