This file contains 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
// 已知数组 A[1··n]的元素类型为整型 int,设计一个时间和空间上尽可能高效的算法 | |
// 将其调整为左右两部分,左边所有元素为奇数,右边所有元素为偶数,不要求对这些元素排序 | |
// (1) 给出算法的基本设计思想: | |
// (2) 根据设计思想,采用 c 语言表述算法,关键之处给出注释: | |
// (3) 说明你所设计算法的时间复杂度和空间复杂度。 | |
#include <iostream> | |
#include <vector> | |
#include <random> | |
using namespace std; |
This file contains 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'; | |
import 'package:flutter/material.dart'; | |
import 'package:flutter/rendering.dart'; | |
void main() { | |
runApp(MyApp()); | |
} | |
class MyApp extends StatelessWidget { | |
@override |
This file contains 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:convert'; | |
import 'dart:math'; | |
import 'dart:typed_data'; | |
import 'dart:ui' as ui; | |
import 'package:flutter/material.dart'; | |
import 'package:flutter/rendering.dart'; | |
void main() => runApp(const MyApp()); |