Only one programming questions. Input a string, including numbers, operands, and brackets. Calculate the result. Test case: input: "(+ 3 3)": Output: 6 input "(* 3 3)" Output: 9 input: "(+ 1 12 (- 17 3) 5 (* 2 8 (/ 120 4)) 46)", Output: 1 + 12 + (17 - 3) + 5 + (2 * 8 * (120 / 4)) + 46 = 558
Software Engineer Asc Interview Questions
419,681 software engineer asc interview questions shared by candidates
Given a message "one two three four five six seven eight nine", chop it in chunks(no exceed the give buffer size) and print out to the screen. Need to maintain the word and do not chop it off. I.E.: buffer size is 15 one two three (1/4) four five six (2/4) seven eight (3/4) nine (4/4)
java
If V is a vector with n items and subroutine Exchange swaps its arguments, then the following code fragment sorts V in descending order. for( j = 0; j < n - 1; j++ ) for( k = 0; k < n - j - 1; k++ ) if( V[k] < V[k+1] ) Exchange( V[k], V[k+1] ); How many calls to Exchange are made if initially, V[i]=i, for i = 0, 1, 2, ..., n - 1 ? a. n-1 b. n c. n(n-1)/2 d. (n-1)(n-2) e. n(n-1)
Buddy bitmap clear bit and event handler
A string for example: AAAAABBBCCCCDD has to be converted into A5B3C4D2.
1 1 2 1 1 3 3 1
- Languages: Different between Java and C++, garbage collector in java (how it work), static vs dynamic memory allocation - Data structures: Linked lists, queues, stacks, heap, trees - OOP: polymorphism, design patterns that I used before - Algorithms: Sorting algorithms I know and there complexity, how to search for a number in an array (sorted and not sorted cases) - Coding question: reverse a single linked list
You have a given set of prices in an Array, find at which price you should buy and at which price you should sell so that you maximize the gain
Given a array of a series of characters (char array from string) reduce multiple spaces to a single space, while preserving the other characters. The swapping needs to take place within the initial array.
Viewing 1881 - 1890 interview questions