当前位置:网站首页>Force buckle 912 Sort array
Force buckle 912 Sort array
2022-07-07 20:06:00 【Tomorrowave】
Code section
Give you an array of integers nums, Please arrange the array in ascending order .
Example 1:
Input :nums = [5,2,3,1]
Output :[1,2,3,5]
Example 2:
Input :nums = [5,1,1,2,0,0]
Output :[0,0,1,1,2,5]
Tips :
1 <= nums.length <= 5 * 104
-5 * 104 <= nums[i] <= 5 * 104
Ideas
Ascending order list.sort()
Code section
class Solution:
def sortArray(self, nums: List[int]) -> List[int]:
nums.sort()
return nums
边栏推荐
- PMP對工作有益嗎?怎麼選擇靠譜平臺讓備考更省心省力!!!
- CSDN语法说明
- 831. KMP string
- Ucloud is a basic cloud computing service provider
- 力扣 989. 数组形式的整数加法
- 【剑指offer】剑指 Offer II 012. 左右两边子数组的和相等
- 关于自身的一些安排
- Tp6 realize Commission ranking
- Classification automatique des cellules de modules photovoltaïques par défaut dans les images de lecture électronique - notes de lecture de thèse
- 关于cv2.dnn.readNetFromONNX(path)就报ERROR during processing node with 3 inputs and 1 outputs的解决过程【独家发布】
猜你喜欢

Some important knowledge of MySQL
![最多可以参加的会议数目[贪心 + 优先队列]](/img/f3/e8e939e0393efc404cc159d7d33364.png)
最多可以参加的会议数目[贪心 + 优先队列]

使用高斯Redis实现二级索引

开源重器!九章云极DataCanvas公司YLearn因果学习开源项目即将发布!

编译器优化那些事儿(4):归纳变量

多个线程之间如何协同

论文解读(ValidUtil)《Rethinking the Setting of Semi-supervised Learning on Graphs》

整型int的拼接和拆分

Force buckle 599 Minimum index sum of two lists

ASP. Net kindergarten chain management system source code
随机推荐
华南X99平台打鸡血教程
9 atomic operation class 18 Rohan enhancement
Openeuler prize catching activities, to participate in?
R language uses ggplot2 function to visualize the histogram distribution of counting target variables that need to build Poisson regression model, and analyzes the feasibility of building Poisson regr
使用高斯Redis实现二级索引
数据孤岛是企业数字化转型遇到的第一道险关
关于自身的一些安排
vulnhub之Funfox2
vulnhub之school 1
TS快速入门-泛型
LeetCode_ 7_ five
Mysql, sqlserver Oracle database connection mode
吞吐量Throughout
PMP对工作有益吗?怎么选择靠谱平台让备考更省心省力!!!
My creation anniversary
LeetCode_7_5
模拟实现string类
PMP對工作有益嗎?怎麼選擇靠譜平臺讓備考更省心省力!!!
ASP. Net learning & ASP's one word
使用高斯Redis实现二级索引