The following function is stripping (removing) all the characters in string stripChars from the end of the string str? The function is incomplete. What code should be there in place of the comment? public static String stripEnd(final String str, final String stripChars) { if (str == null) return str; int end = str.length(); int INDEX_NOT_FOUND = -1; if(end == 0) return str; else if (stripChars.isEmpty()) { return str; } else { // ********************* // What's the code here? // ********************* } return str.substring(0, end); } while (end != 0 && str.indexOf(stripChars.charAt(end - 1)) == INDEX_NOT_FOUND) { end++; } while (end != 0 && str.indexOf(stripChars.charAt(end - 1)) != INDEX_NOT_FOUND) { end--; } while (end != 0 && stripChars.indexOf(str.charAt(end - 1)) != INDEX_NOT_FOUND) { end--; } while (end != 0 && stripChars.indexOf(str.charAt(end - 1)) == INDEX_NOT_FOUND) { end++; }
Android Software Developer Interview Questions
8,366 android software developer interview questions shared by candidates
Name the different stages of an android activity.
what is MVP
String reverse. Tree(data structure) related question.
2nd skype: - Lets say you have to build an activity (screen) which has a drop-down & once you select an item in the drop-down, it loads an image corresponding to that on the screen below. - How will handle cases where user is very rapidly changing his selection from the drop down
How the viewpager is implemented?
1. Android components 2. App lifecycle. 3. Design pattern
Which Android frameworks do you use?
Implement a solution for displaying the data payload from the backend.
Given a dictionary of English words, write a function that will determine whether a string is an English sentence, i.e. whether that string is constructed of english words.
Viewing 31 - 40 interview questions