Flutter
-
[Flutter 플러터] Lotto 프로그램 만들기 (중복 제외, 오름차순 정렬까지)Study/Flutter, Dart 2024. 9. 27. 15:46
Lotto 프로그램 import 'dart:math';List lottoNumber(){ List lottoList = []; var num; for(int i = 0; i myNumber(){ List myList = []; var num; for(int i = 0; ilottoFinal = lottoNumber(); ListmyFinal = myNumber(); checkNumber(lottoFinal, myFinal);} 1. lottoNumber(), myNumber() 함수를 만들어서 정수형 리스트를 반환한다. 2. for문을 사용하여, 1~45중 랜덤하게 뽑아, lottoList, myList에 넣는다. 3. checkNumber 함수를 통해 lottoList의 각 번호와 ..
-
[Flutter 플러터] 인스타그램 앱 따라 만들기Study/Flutter, Dart 2024. 9. 12. 18:05
인스타그램 앱 따라 만들기 main.dartimport 'package:flutter/cupertino.dart';import 'package:flutter/material.dart';import 'package:google_fonts/google_fonts.dart';import 'body.dart';void main() { runApp(const InstaCloneApp());}class InstaCloneApp extends StatelessWidget { const InstaCloneApp({super.key}); @override Widget build(BuildContext context) { return MaterialApp( theme: ThemeData( ..
-
[Flutter 플러터] 가위바위보 앱 따라 만들기Study/Flutter, Dart 2024. 9. 10. 11:04
가위바위보 앱 만들기 main.dartimport 'package:flutter/material.dart';import 'package:rsp_game/game/game_body.dart';void main() { runApp(const RSPAPP());}class RSPAPP extends StatelessWidget { const RSPAPP({super.key}); // This widget is the root of your application. @override Widget build(BuildContext context) { return MaterialApp( home: Scaffold( appBar: AppBar( title: const..
-
[Flutter 플러터] 9. Flutter에서 화면 이동하기Study/Flutter, Dart 2024. 8. 27. 16:50
Flutter에서 화면 이동하기1. 상태를 관리해서 화면 이동하기import 'package:english_words/english_words.dart';import 'package:flutter/cupertino.dart';import 'package:flutter/material.dart';import 'package:flutter/widgets.dart';const assetImagePath = 'assets/images';const bannerImage = '$assetImagePath/apple.jpeg';void main() { runApp( MaterialApp( home: Scaffold( appBar: AppBar( backgroundC..
-
[Flutter 플러터] 8. 플러터 라이브러리 사용하기Study/Flutter, Dart 2024. 8. 17. 15:27
Flutter의 Callbackimport 'package:flutter/cupertino.dart';import 'package:flutter/material.dart';void main() { runApp( MaterialApp( home: Scaffold( appBar: AppBar( backgroundColor: Colors.lightBlue, title: const Text('flutter의 Callback'), ), body: const Body()), ), );}class Body extends StatelessWidget { const Body({super.key}); @override Wid..