33. 突然ですがクイズです
• Gmail / Google+ / Twitter を利用
し、任意の文字列を送信するAndroid
アプリを作るのに必要な時間は?
A. 3分
B. 3時間
C. 3日
D. Androidでは無理... だけど...
3秒でできるよ。そう、iPhoneならね 33
34. これだけ書けば解決!
public class Test extends Activity {
/** Called when the activity is first created. */
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
new AlertDialog.Builder(this).setMessage("Start activity ?")
.setPositiveButton("Yes", new DialogInterface.OnClickListener() {
public void onClick(DialogInterface dialog, int whichButton) {
Intent intent = new Intent(Intent.ACTION_SEND);
intent.setType("text/plain");
intent.putExtra(Intent.EXTRA_TEXT, "Hello, Android!!");
startActivity(intent);
}
}).setNegativeButton("No", null).show();
}
}
34
41. 突然ですがクイズです パート2
• 青空読手のユーザの 10% が ¥210-
で購入してくれていたとすると、これまでに
私の懐にいくら入っていたでしょう?
A. ¥400,000-
B. ¥4,000,000-
C. ¥40,000,000-
D. もっと稼げる。そう、iPhone ならね
41