Skip to content

Instantly share code, notes, and snippets.

View gustavolhonda's full-sized avatar

Gustavo Lamin Honda gustavolhonda

View GitHub Profile
Stream<String> delayedTextStream() async* {
for (int i = 1; i <= 5; i++) {
await Future.delayed(Duration(seconds: 2));
yield 'Text $i';
}
}
Future<void> main() async {
Stream<String> stream = delayedTextStream();
@gustavolhonda
gustavolhonda / mainScreen.kt
Created May 14, 2025 15:04
Basketball Jetpack Compose
package com.example.basketballjetpack
import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.Row
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.padding
import androidx.compose.material3.Button
import androidx.compose.material3.Scaffold
import androidx.compose.material3.Text
@gustavolhonda
gustavolhonda / Corotinas2.kt
Created April 24, 2025 14:34
JetPack Compose - Gustavo Honda
package com.example.firstkotlin
import kotlinx.coroutines.Deferred
import kotlinx.coroutines.async
import kotlinx.coroutines.delay
import kotlinx.coroutines.launch
import kotlinx.coroutines.runBlocking
import kotlin.random.Random
import kotlin.time.Duration
import kotlin.time.Duration.Companion.seconds
@gustavolhonda
gustavolhonda / MainActivity.java
Created April 14, 2025 23:52
PC.02 - Grupo 1
package com.example.basketball;
import android.os.Bundle;
import android.widget.Button;
import android.widget.TextView;
import androidx.activity.EdgeToEdge;
import androidx.appcompat.app.AppCompatActivity;
import androidx.core.graphics.Insets;
import androidx.core.view.ViewCompat;