UPWORK ANDROID PROGRAMING TEST 2016
It is tough to answer the questions in a short time. Here we have categorized the questions. When you are going to seat for exam, follow the categories to answer them. Hope you can find the answer in shorter time.Upwork Test Answer Adobe Illustrator cs6
Upwork US English Basic Skills Test-2016
Upwork readiness test for beginners - 2016
QUESTIONS ABOUT ''CODING''
1. Consider the code snippet below:
MediaPlayer mp = new MediaPlayer();
mp.setDataSource(PATH_TO_FILE);
<Some code here>
mp.start();Which of the following should be placed at <some code here>?
- mp.prepare();
- mp.prepareAsync();
- mp.loadMedia();
- mp.loadSource();
- mp.loadSource; mp.prepare();
- no code is required at <some code here> to start back.
2. Consider the XML fragment below, which is taken from one of the files in an Android project:
<MyElement xmls:"http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:text="Some Text>
</MyElement>
Which one of the are true about the XML fragment above?
- It is taken from the manifest XML file of the Android project.
- It is taken from an XML file used to define a view.
- It is taken from the package file (.apk) of the Android project.
- The xmlns: attribute is a compulsory attribute.
- If this is not the outer most tag in the XML file then it need not contain the xmlns: attribute
- MyElement should be the name of a class derived, directly or indirectly, from the view class.
3. Consider the following snippet of code:
<font size =2>
@Override
protected void onStop
{
Super.onStop();
SharedPreferences setting = getSharedPreferences(“MyPrefs”, 0);
SharedPreferences.Editor editor = settings.edit();
editor.putBoolean(“MyBool”, true);
<some more code here>
}
Which of the following should be used <some more code
here>?