Showing posts with label Android Job Guider.. Show all posts
Showing posts with label Android Job Guider.. Show all posts

Tuesday, 10 December 2013

Android interview question

Interview Question for Intermediate level

What is Persistent and Non-Persistent object in android?
Ans:-

       Persistent Objects:- an application appears to continue running, the system may choose to kill its process and restart it later.

For sharing complex persistent user-defined objects, the following approaches are recommended:
·         Application Preferences
·         Files
·         contentProviders
·         SQLite DB
Non-Persistent object:
For sharing complex non-persistent user-defined objects for short duration, the following approaches are recommended:
 
What is portable Wi-Fi hotspot?
Ans:
       The portable Wi-Fi® hotspot feature allows you to share your mobile device’s data connection with other devices by turning your device into a wireless access point. You can connect up to 8 wireless devices via Wi-Fi.
 
What is the difference between a regular bitmap and a nine-patch image?
Ans:
       It is one of a resizable bitmap resource which is being used as backgrounds or other images on the device. The NinePatch class allows drawing a bitmap in nine sections. The four corners are unscaled; the middle of the image is scaled in both axes, the four edges are scaled into one axis.
 
Explain about the exceptions of Android?
Ans.
What is ,dex extension. What is the significance of the .dex files?
Ans.
       Android programs are compiled into .dex (Dalvik Executable) files, which are in turn zipped into a single .apk file on the device. .dex files can be created by automatically translating compiled applications written in the Java programming language
 
What is the difference between Service and Thread?
Ans:
·                   Service is like an Activity but has no interface. Probably if you want to fetch the weather for example you won't create a blank activity for it, for this you will use a Service.
·         A Thread is a Thread, probably you already know it from other part. You need to know that you cannot update UI from a Thread. You need to use a Handler for this, but read further.
·         An AsyncTask is an intelligent Thread that is advised to be used. Intelligent as it can help with it's methods, and there are two methods that run on UI thread, which is good to update UI components
 
What is the importance of XML-based layouts?
Ans:
The use of XML-based layouts provides a consistent and somewhat standard means of setting GUI definition format. In common practice, layout details are placed in XML files while other items are placed in source files.
 
What is the importance of settings permissions in app development in Android?
Ans:
       Permissions allow certain restrictions to be imposed primarily to protect data and code. Without these, codes could be compromised, resulting to defects in functionality.
 
 
What is an URIs? 
Ans:
 
An uniform resource identifier (URI) is a string of characters used to identify a name of a web resource
 A URI reference includes a URI and a fragment, the component of the URI following a '#'. Builds and parses URI references which conform to RFC 2396.
 
Can I write code for Android using C/C++?
Ans:
Yes, using NDKyou can write but it too complex so avoid this.
 
Does Android support the Bluetooth serial port profile?
Ans:
       The most common type of Bluetooth socket is RFCOMM, which is the type supported by the Android APIs. RFCOMM is a connection-oriented, streaming transport over Bluetooth. It is also known as the Serial Port Profile (SPP).
      
How to select more than one option from list in android xml file? 
       Specify android id, layout height and width as depicted in the following example.
 
What is Mono in Android?
Ans:
Mono is a free and open source project led by Xamarin (formerly by Novell and originally by Ximian) to create an Ecma standard-compliant, .NET Framework-compatible set of tools including, among others, a C# compiler and a Common Language Runtime.
 
 
What are the differences between a domain and a workgroup?

Ans:
      
In a domain, one or more computer can be a server to manage the network. On the other hand in a workgroup all computers are peers having no control on each other. In a domain, user doesn’t need an account to logon on a specific computer if an account is available on the domain. In a work group user needs to have an account for every computer. 
In a domain, Computers can be on different local networks. In a work group all computers needs to be a part of the same local network. 
 
Explain IP datagram, Fragmentation and MTU.
Ans:
IP datagram can be used to describe a portion of IP data. Each IP datagram has set of fields arranged in an order. The order is specific which helps to decode and read the stream easily. IP datagram has fields like Version, header length, Type of service, Total length, checksum, flag, protocol, Time to live, Identification, source and destination ip address, padding, options and payload.
MTU:- Maximum Transmission Unit is the size of the largest packet that a communication protocol can pass. The size can be fixed by some standard or decided at the time of connection
Fragmentation is a process of breaking the IP packets into smaller pieces. Fragmentation is needed when the datagram is larger than the MTU. Each fragment becomes a datagram in itself and transmitted independently from source. When received by destination they are reassembled. 
Why Activitylife cycle is must. What are the Different phases of Activity Life cycle. For example: when and how the activity comes to foreground?



The square rectangles represent callback methods you can implement to perform operations when the Activity moves between states. The colored ovals are major states the Activity can be in.

Android InterVeiw Question

Interview Question for Beginner


It is an open-sourced operating system that is used primarily on mobile devices, such as cell phones and tablets. It is a Linux kernel-based system that’s been equipped with rich components that allows developers to create and run apps that can perform both basic and advanced functions.


2) What Is the Google Android SDK? 

The Google Android SDK is a toolset that developers need in order to write apps on Android enabled devices. It contains a graphical interface that emulates an Android driven handheld environment, allowing them to test and debug their codes.


Android Architecture is made up of 4 key components:
- Linux Kernel
- Libraries
- Android Framework
- Android Applications


4) Describe the Android Framework. 

The Android Framework is an important aspect of the Android Architecture. Here you can find all the classes and methods that developers would need in order to write applications on the Android environment.


5) What is AAPT? 

AAPT is short for Android Asset Packaging Tool. This tool provides developers with the ability to deal with zip-compatible archives, which includes creating, extracting as well as viewing its contents.


6) What is the importance of having an emulator within the Android environment? 

The emulator lets developers “play” around an interface that acts as if it were an actual mobile device. They can write and test codes, and even debug. Emulators are a safe place for testing codes especially if it is in the early design phase.


7) What is the use of an activityCreator? 

An activityCreator is the first step towards the creation of a new Android project. It is made up of a shell script that will be used to create new file system structure necessary for writing codes within the Android IDE.


8 ) Describe Activities. 

Activities are what you refer to as the window to a user interface. Just as you create windows in order to display output or to ask for an input in the form of dialog boxes, activities play the same role, though it may not always be in the form of a user interface.


9) What are Intents? 

Intents displays notification messages to the user from within the Android enabled device. It can be used to alert the user of a particular state that occurred. Users can be made to respond to intents.


10) Differentiate Activities from Services. 

Activities can be closed, or terminated anytime the user wishes. On the other hand, services are designed to run behind the scenes, and can act independently. Most services run continuously, regardless of whether there are certain or no activities being executed.

Today's Pageviews