13,663 reputation
22555
bio website
location
age
visits member for 3 years, 7 months
seen 8 mins ago

1h
comment Where do programmers look for reference/documentation about Java's features/libraries/functions?
I'll just leave this here: docs.oracle.com/javase/7/docs/api also there is a downloadable format for offline access
2d
comment How to keep legal rights when hired to make a program
it depends on the contract you sign, read it through and probably get some help from a lawyer that knows about such things
2d
comment Input data type conflict causing infinite loop
reading the help center is a good start: programmers.stackexchange.com/help/on-topic
2d
comment Input data type conflict causing infinite loop
This question appears to be off-topic because it is about debugging a program.
2d
comment What is a good word for the current “state” of a state machine?
State state = State.START_STATE;
2d
comment Notepad++ is making my .html.erb files highlighted odd colors
it's the default background highlighting check settings->style configurator and select ruby then adjust as you please
Dec
13
comment std::memory_order_relaxed modification order consistency
it's meant for initialization of a group of atomic ints so only 1 fence gets produced
Dec
13
comment What's the purpose of keeping a changelog if everyone uses their VCS properly?
People use changelogs, though you can often generate them from commit messages
Dec
13
comment Is it possible to quickly change an array declared on the stack to one declared on the heap
you'll need to delete it later as well
Dec
13
comment Permutting a list of numbers in order to get a list which satisfies given condition
Because they are the ones closest to all the others, putting them at the ends eliminates one distance from each of them. your method can be improved simply by putting the last number you add to the beginning.
Dec
13
comment Permutting a list of numbers in order to get a list which satisfies given condition
I'd say the beginning and end should contain the 2 middle numbers (the median and number closest to it)
Dec
12
comment Searching algorithm used in switch statement
@MichaelT then the compiler would just copy the code of case 2 to after case 1 or make it a if cascade with goto endSwitch; for each break.
Dec
12
comment Why GCC does this?
Creating a compiler is hard. It's doubly hard when the language is specified by committee.
Dec
12
comment Java card game design decision
@userx01 the cursor can have a Stack that holds at most 1 card it gets the card from the Stack under the cursor when mouse down and tries to put down the card on mouse up, resetting if it fails.
Dec
11
comment What is the use of Runnable r = new Runnable();
It's not valid java as Runnable is an interface, you can't instantiate it directly.
Dec
11
comment Do compilers attach the Garbage Collector to the final executable?
GC is often language specific, there are C++ GC implementations that get included by either a static library or a DLL.
Dec
10
comment Is Hyper Text Transfer Protocol (HTTP) a misnomer?
@ampt just like a **** by any other name would stink just as bad.
Dec
10
comment Does TCP guarantee packet transmission time?
best effort only, it can't help if the IP layer can't deliver.
Dec
10
comment Is there ever a reason to use an array when lists are available?
@InstructedA in C# it is.
Dec
10
comment Is there ever a reason to use an array when lists are available?
For a hash table you can use an array and when you need to grow the table you need to set the elements to the new positions based on hash%newArray.length anyway.