Skip to content

Instantly share code, notes, and snippets.

@mcz9mm
Last active August 29, 2019 02:23
Show Gist options
  • Save mcz9mm/58eb52907fed4bbb7e3c4f1d4ff557b4 to your computer and use it in GitHub Desktop.
Save mcz9mm/58eb52907fed4bbb7e3c4f1d4ff557b4 to your computer and use it in GitHub Desktop.
Kotlin tutorial

No1. leap year

create method isLeapyear

require:

Parameters: year(Int) Return type: Bool

Examples

println(leapyear(2000)) // true
println(leapyear(1209)) // false
println(leapyear(1980)) // true
println(leapyear(1790)) // false
println(leapyear(1993)) // false

No2. Janken game

Create method Janken game. Please output the result in the method

require:

enum HandType enum Reslut

Parameters: (you: HandType) Return type: nil

※cp hand is ramdom hand

Examples

janken(HandType.rock)
// cp: scissors. you win!
janken(HandType.scissors)
// cp: rock. you lose
janken(HandType.paper)
// cp: paper. you draw

No3. leap year app

require:

  • Button
  • TextView
  • TextInput

Examples

tutorial

No4. Janken Game App

require:

  • Button
  • TextView
  • ImageView

スクリーンショット 2019-05-17 22 40 16

Want function

  • Random Animation

No.5 Qiita API Client

request api: https://qiita.com/api/v2/items?page=1&per_page=20

require:

  • Fragment

  • RecyclerView

  • Retrofit2

  • Perform screen transition

Documents

qiita api

https://qiita.com/api/v2/docs

May-17-2019 23-58-40

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment