ex 11234567891011121314/** * EX 1 : * Write a code snippet that sets a to an array of n random integers between 0 (inclusive) and n (exclusive). * * @param n * @return */priv...
ex 11234567891011/** * ex 1 : * The signum of a number is 1 if the number is positive, –1 if it is negative, and 0 if it is zero. Write a * function that computes this value. * * @...
problemwhen run spark job to write data to es cluster on aws, I got error like this:
12345678910111213141516171819/01/09 16:18:41 WARN TaskSetManager: Lost task 0.0 in stage 0.0 (T...
after fork a project on github, you may also need to sync your repo with the original repo you forked from, how to do that?
add upstream1git remote add upstream git@github.intuit....
How to design an elevator systemthis is a famous interview questions. Design a elevator system would never be an easy task. How to ship people efficiently and quickly without over ...
manacher’s algorithmwhat’s it?manacher’s algorithm is good at calculate palindrome string, the time-complexity can reach o(n). it would re-use the pattern to calcuate, so it is ver...
Binary searchbinary search is prety tricky and have a lot hidden dents, here is my summary.
Common problem
given a non-descending array, find element with value m in the array.
b...