26/06/2022
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import 'dart:math'; | |
| void main() { | |
| // final p = [ 0, 1, 5, 8, 9, 10, 17, 17, 20, 24, 30, 32, 35, 39, 43, 43, 45, 49, 50, 54, // 1X's | |
| // 57, 60, 65, 68, 70, 74, 80, 81, 84, 85, // 2X's | |
| // 87, 91, 95, 99, 101, 104, 107, 112, 115, 116, // 3X's | |
| // 119, 121, 125, 129, 131, 134, 135, 140, 143, 145, // 4X's | |
| // 151 | |
| // ]; | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| void main() { | |
| final autodata = "gs://aksdjasdsad"; | |
| final autoCheckRx = RegExp('(?:(?: G|^gs://)|(?: G|^https:))'); | |
| print(autoCheckRx.hasMatch(autodata)); | |
| } |
Add D: location folder C:...........> cd D:....\flutter_practice
add "d:" C:...........> d:
"flutter crate ...." D:....\flutter_practice> flutter crate ....
Kata : https://www.codewars.com/kata/525e5a1cb735154b320002c8/train/dart
void main() {
// print(" - ".trim() == '-');
var _value = 0;
for (int i = 14999; i > 0; i--){
_value += i;
}
/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/bundler_version_finder.rb:80:in `pwd': Operation not permitted - getcwd (Errno::EPERM)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Tambah variable state provider untuk nilai yang bisa di ubah2. | |
| final pageIndexProvider = StateProvider<int>((ref) => 1); | |
| // Tambah provider yang hanya bisa update jika nilai dari pageIndexProvider | |
| // ! note: Nilai dalam provider tidak bisa di ubah dari luar, untuk menghindari rebuild yang tidak perlu. | |
| final canGoToPreviousPageProvider = Provider<bool>((ref) { | |
| return ref.watch(pageIndexProvider) == 0; | |
| }); | |
| class PreviousButton extends ConsumerWidget { |
mungkin itu disebabkan timezone php dan timezone db beda,
jadi isi si db sama laravel dianggap bukan waktu utc sama si php diconvert jadi waktu utc alias dipotong 7 jam.
a. persiapan pertama project
-
StatefulWidget: State widget yang digunakan. -
Variable animasi : variable untuk menentukan animasi page dan widget.
late AnimationController _animationController;
late AnimationController _mapAnimationController;
final PageController _pageController = PageController();