๐
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
| {"version":1,"resource":"file:///Users/user1/Desktop/ho/happymeal/src/app/%28public%29/%28tabs%29/explore.tsx","entries":[{"id":"yLjF.tsx","timestamp":1741588339252},{"id":"ZEEZ.tsx","timestamp":1741588644563},{"id":"OBAD.tsx","source":"undoRedo.source","timestamp":1741588647400},{"id":"H8He.tsx","timestamp":1741588760227}]} |
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
| ZX Utility... | |
| const projectRoot = cwd(); | |
| export let VERSION_NAME = ''; | |
| export let VERSION_CODE = ''; | |
| async function init() { | |
| const content = read(resolve(projectRoot, 'app.config.ts')); | |
| VERSION_NAME = /const VERSION_NAME = '(.*?)';/.exec(content)[1]; |
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
| class **$NAME$**Adapter : RecyclerView.Adapter<**$NAME$**Adapter.Holder>() { | |
| private var items: List<**$DATA$**> = listOf() | |
| fun submitList(items: List<**$DATA$**>) { | |
| this.items = items | |
| notifyDataSetChanged() | |
| } | |
| override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): Holder { | |
| val inflater = LayoutInflater.from(parent.context) | |
| val binding = Item**$NAME$**Binding.inflate(inflater, parent, false) | |
| return Holder(binding) |
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
| data class MyData(val id: Int) | |
| class MyAdapter : RecyclerView.Adapter<MyAdapter.Holder>() { | |
| private var items: List<MyData> = listOf() | |
| fun submitList(items: List<MyData>) { | |
| this.items = items | |
| notifyDataSetChanged() | |
| } | |
| override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): Holder { | |
| val inflater = LayoutInflater.from(parent.context) |
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:async'; | |
| main() { | |
| print('main #1 of 2'); | |
| scheduleMicrotask(() => print('microtask #1 of 3')); | |
| new Future.delayed( | |
| new Duration(seconds: 1), () => print('future #1 (delayed)')); | |
| new Future(() => print('future #2 of 4')) |
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:async'; | |
| main() { | |
| print(1); | |
| futureNoDelay(2).then(print); | |
| future(3).then(print); | |
| futureSync(4).then(print); | |
| futureSyncReturnFuture(5).then(print); | |
| futureSyncReturnFutureValue(6).then(print); | |
| futureValue(7).then(print); |
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() async { | |
| runZonedGuarded(() { | |
| print('Hi I am in a new zone'); | |
| throw 1; | |
| }, (e, s) { | |
| print(e); | |
| }); |
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:isolate'; | |
| printIsolateName() { | |
| print(Isolate.current.debugName); | |
| } | |
| void main() async { | |
| printIsolateName(); // main | |
| Future.delayed(Duration(seconds: 0)).then((_) { | |
| printIsolateName(); // main |
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
| n, m = map(int, input().split()) | |
| a = list(map(int, input().split())) | |
| psum = [0] * (n + 1) | |
| for i in range(n): | |
| psum[i + 1] = (psum[i] + a[i]) % m | |
| answer = 0 | |
| remainder_cnt = [0] * m |
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
| n, k, b = map(int, input().split()) | |
| active = [1 for _ in range(n + 1)] | |
| for i in range(b): | |
| broken = int(input()) | |
| active[broken] = 0 | |
| active[0] = 0 | |
| answer = 10 ** 9 |
NewerOlder