Android Developer Intern Interview Questions

8,369 android developer intern interview questions shared by candidates

What will be the return value of someCoolFunction("[ab][bc][ca]", "[", "]")? public static String[] someCoolFunction(String str, String open, String close) { if (str == null || open == null || close == null) { return null; } int strLen = str.length(); if (strLen == 0) { return null; } int closeLen = close.length(); int openLen = open.length(); List list = new ArrayList(); int pos = 0; while (pos < (strLen - closeLen)) { int start = str.indexOf(open, pos); if (start < 0) { break; } start += openLen; int end = str.indexOf(close, start); if (end < 0) { break; } list.add(str.substring(start+1, end)); pos = end + closeLen; } if (list.isEmpty()) { return null; } return (String[]) list.toArray(new String [list.size()]); } ["bb", "cc", "da"] ["a", "b", "c"] ["ab", "bc", "ca"] ["b", "c", "a"] ["c", "b", "a"] Question 4 A perfect number is a positive integer that is equal to the sum of its proper positive divisors (factors) excluding the number itself. Complete the following function which determines whether a given number is perfect or not. int perfect(int n) { int tot = 1; int i; // ********************* // What's the code here? // ********************* return tot == n; } for (i = 2; i < n; i++) { if ( (i % n) != 0 ) { tot += i; } } for (i = 2; i < n; i++) { if ( (i % n) == 0 ) { tot += i; } } for (i = 2; i < n; i++) { if ( (n % i) == 0 ) { tot += i; } } for (i = 2; i < n; i++) { if ( (n % i) != 0 ) { tot += i; } }
avatar

Android Developer

Interviewed at Smartprix

3.4
Aug 3, 2016

What will be the return value of someCoolFunction("[ab][bc][ca]", "[", "]")? public static String[] someCoolFunction(String str, String open, String close) { if (str == null || open == null || close == null) { return null; } int strLen = str.length(); if (strLen == 0) { return null; } int closeLen = close.length(); int openLen = open.length(); List list = new ArrayList(); int pos = 0; while (pos < (strLen - closeLen)) { int start = str.indexOf(open, pos); if (start < 0) { break; } start += openLen; int end = str.indexOf(close, start); if (end < 0) { break; } list.add(str.substring(start+1, end)); pos = end + closeLen; } if (list.isEmpty()) { return null; } return (String[]) list.toArray(new String [list.size()]); } ["bb", "cc", "da"] ["a", "b", "c"] ["ab", "bc", "ca"] ["b", "c", "a"] ["c", "b", "a"] Question 4 A perfect number is a positive integer that is equal to the sum of its proper positive divisors (factors) excluding the number itself. Complete the following function which determines whether a given number is perfect or not. int perfect(int n) { int tot = 1; int i; // ********************* // What's the code here? // ********************* return tot == n; } for (i = 2; i < n; i++) { if ( (i % n) != 0 ) { tot += i; } } for (i = 2; i < n; i++) { if ( (i % n) == 0 ) { tot += i; } } for (i = 2; i < n; i++) { if ( (n % i) == 0 ) { tot += i; } } for (i = 2; i < n; i++) { if ( (n % i) != 0 ) { tot += i; } }

1.Technical Questions are:- a) factorial b) find minimum element in an array c) find second minimum element in an array d) palindrome program e) string reverse without using inbuilt functions and 2-3 more(don't remember) 2.In the technical interview, they would ask you the basics of the profile for which you are applying. 3. Interview with CEO/COO is pretty cool. They just wanna know about you and they might give some puzzle. Also, they may ask you to correct your code of technical round. 4. Basic questions, salary, about you, hobbies etc.

Android Developer

Interviewed at CodeYeti

3.8
Sep 9, 2016

1.Technical Questions are:- a) factorial b) find minimum element in an array c) find second minimum element in an array d) palindrome program e) string reverse without using inbuilt functions and 2-3 more(don't remember) 2.In the technical interview, they would ask you the basics of the profile for which you are applying. 3. Interview with CEO/COO is pretty cool. They just wanna know about you and they might give some puzzle. Also, they may ask you to correct your code of technical round. 4. Basic questions, salary, about you, hobbies etc.

Questions involved : 1. Describe Activity and Fragments (how fragment attaches to the Activity) and other related things. 2. Thread vs AsyncTasks (Advantages and Disadvantages of each) 3. What happens when you rotate the screen while on an Activity (and related things on ConfigChanges) 4. New features in Android 7.0 5. DOM vs SAX in XML parsing 6. What happens in setContentView in Activity 7. Why do we use XML instead of COding the UI part.
avatar

Android Developer

Interviewed at Daon

4
Apr 23, 2017

Questions involved : 1. Describe Activity and Fragments (how fragment attaches to the Activity) and other related things. 2. Thread vs AsyncTasks (Advantages and Disadvantages of each) 3. What happens when you rotate the screen while on an Activity (and related things on ConfigChanges) 4. New features in Android 7.0 5. DOM vs SAX in XML parsing 6. What happens in setContentView in Activity 7. Why do we use XML instead of COding the UI part.

Viewing 1001 - 1010 interview questions

Glassdoor has 8,369 interview questions and reports from Android developer intern interviews. Prepare for your interview. Get hired. Love your job.