목록전체 글 (31)
개발부터 자유까지

목차유니코드와 문자열ord 함수chr 함수중제목3 유니코드와 문자열유니코드가 나오기 전에 아스키 코드가 있었다. 아스키 코드는 영문자를 대상으로 문자를 숫자로 맵핑하기 위한 체계이다.총 128개의 문자를 7bit로 표현하고 1bit는 통신 에러 검출을 위해 사용하기 때문에 총 8bit로 표현한다. 아스키 코드 (ASCII) - American Standard Code for Information Interchange 범위: 아스키 코드는 7비트로 표현되어 총 128개의 문자를 담을 수 있습니다 (0~127까지의 정수값).지원문자: 아스키 코드는 주로 영문 알파벳, 숫자, 일부 특수 문자 및 제어 문자를 포함합니다.사용: 초기 컴퓨터 시스템에서 널리 사용되었으며, 영어를 사용하는 텍스트를 처리하는 데 적합..
1422. Maximum Score After Splitting a String Given a string s of zeros and ones, return the maximum score after splitting the string into two non-empty substrings (i.e. left substring and right substring).The score after splitting a string is the number of zeros in the left substring plus the number of ones in the right substring. Example 1:Input: s = "011101"Output: 5 Explanation: All possible ..

flutter 패키지인 introduction_screen 버전을 추가하고 pub getintroduction_screen에 들어갈 이미지 파일들이 있는 image 디렉토리를 asset 속성에 추가name: flutter_practicedescription: "A new Flutter project."# The following line prevents the package from being accidentally published to# pub.dev using `flutter pub publish`. This is preferred for private packages.publish_to: 'none' # Remove this line if you wish to publish to pub.devve..

main.dart, ScreenA.dart, ScreenB.dart, ScreenC.dart 4개 파일로 이루어짐MaterialApp위젯에서 home 대신 initalRoute, routes을 사용해 페이지 이동 (home과 initalRoute를 동시에 사용하면 error 발생)main.dart에서 routes는 Map 형식으로 key는 해당 페이지 주소, value는 해당 페이지를 구성된다.해당 페이지 주소인 key는 ScreenA 페이지에서 TextButton을 눌렀을 때, 호출되는 Navigator의 pushNamed 메소드와 연결된다. // main.dartimport 'package:flutter/material.dart';import 'package:flutter_practice/Screen..

Navigator widget은 stack 구조로 push, pop 함수를 사용해서 페이지를 라우팅한다.Navigator widget이 push, pop 할 때, 해당 페이지를 BuildContext의 context를 통해서 식별한다. import 'package:flutter/material.dart';import 'package:fluttertoast/fluttertoast.dart';void main() => runApp(const MyApp());class MyApp extends StatelessWidget { const MyApp({super.key}); @override Widget build(BuildContext context) { return const MaterialA..

Column widget, Row widget은 레이아웃 잡는데 필수라고 해도 무방할 정도로 자주 쓰이는 위젯이다.코드에 주석 처리되어 있는 것들도 하나씩 해보고 참고 링크를 통해 속상값이 내가 생각한 것처럼 동작하는지 확인할 수 있다.import 'package:flutter/material.dart';import 'package:fluttertoast/fluttertoast.dart';void main() => runApp(const MyApp());class MyApp extends StatelessWidget { const MyApp({super.key}); @override Widget build(BuildContext context) { return const MaterialApp(..
Container 위젯 특징MarginPaddingOnly one childhttps://api.flutter.dev/flutter/widgets/Container-class.html?_gl=1*1e9zrgq*_ga*OTQ2NTcyMDgxLjE3MjU5Nzk2MTk.*_ga_04YGWK0175*MTcyNTk3OTYxOC4xLjEuMTcyNTk4MDcxNC4wLjAuMA.. Container class - widgets library - Dart APIA convenience widget that combines common painting, positioning, and sizing widgets. A container first surrounds the child with padding (inflate..

Builder Widget 없이 스낵바 만들기강의에서는 RaisedButton으로 구현했지만 deprecated 됨ElevatedButton으로 대체 구현함 main.dartimport 'package:flutter/material.dart';void main() => runApp(const MyApp());class MyApp extends StatelessWidget { const MyApp({super.key}); @override Widget build(BuildContext context) { return MaterialApp( title: 'AppBar', theme: ThemeData(primarySwatch: Colors.red), home: const..