-
Notifications
You must be signed in to change notification settings - Fork 150
算法训练营第一周作业 #1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
|
怎么知道自己的学号 |
学号:002 Username:cwbcheng |
学号:007 Username:v1xingyue |
学号:061 otkinlife(贾凯超) |
学号:026 Username:Fanlu91 |
学号:091 Username:DevinSu(籍东文) |
学号:027 Username:zjg23 |
学号:086 Username: SherryShi0108 |
学号:024 Username: lglove(李戈) |
学号:126 Username:suncen0505 |
LeetCode_24_2.cs 两两交换链表中的节点 的题目,感觉还是递归更适合一些,while循环的处理方式中来回赋值好多次,容易乱,不知道你在开发的时候遇到付错值的情况没有,我在写的时候,画图处理,但是发现还是有一个地方没有想清楚。 |
go语言的,好像头一次看go语言,哈哈 :=(声明并赋值) 这个都没有看懂,去百度了 |
还没有做到你的这142题,果断退出,等我自己做一遍后再来回复 |
83题: |
多种语言。。。 |
2 similar comments
多种语言。。。 |
多种语言。。。 |
可以把题目的文件名换成老师给定的格式,这样方便对应题目。还有就是leetcode上直接写代码,他会帮忙验证好多种边界,感觉还挺好的,自己去做验证 ,可能有想不到的边界情况 |
1、学号:155 Username:zhaozhifu0 |
1、学号:008 Username:WuLei |
学号:023 Username:ericyang89 |
1、学号:131 Username:HongChao6 |
学号:038 Username:jianghaoyuan2007 |
学号:141 Username:smz198181 |
学号:003 Username:battlezh |
学号:040 Username:salanhess |
学号:062 Username:shimmer236 |
学号:019 User_name:张进 |
学号: 025 User_name:张家琛 |
学号: 047 User_name:文灿 |
学号:006 Username:yuqiu-pp |
感谢点评。 |
学号:109 Username:quanhoucun |
|
|
153题思路挺简洁的,求中间值的地方建议可以改成mid = low + ((high - low) >> 1),防止溢出 |
测试代码自己撸的啊,感觉可以直接复制leetcode里的,能省不少时间 |
虽然代码提交的方式和老师要求的不一样,但看起来你这个效果更好呀,题目答案在一起,不用分开找了,但在编辑的时候更费事儿吧 |
学号:039 Username: plin005 |
这段代码服了,要是不看上面的注释,真不知道啥意思,这块儿比较的实现看了好多版本,你的是效率最高的了吧,直接减完事儿 |
(A[i] & 1) == 0 通过和1 & 等于0 还是1 来判断奇偶,比 直接取余 效率高不少,这个二进制不熟的,写不来 |
学号:132 Username:wwb4694376 |
这里需要对acsII比较熟悉,在编码的时候,可以查一下acsii码对照表http://ascii.911cha.com。 |
哈哈 回头来看大家之前写的总结来了,算法的开始,时间复杂度和空间复杂度 |
第一个提交作业的,看你当时状态也是刚刚开始找感觉,希望之后也可以一直坚持学习算法,课程最后一次作业留言,一起加油 |
学号:056 Username:刘姝睿 |
学号:020 Username:lcfgrn |
学号:008 Username:Uriah6140 |
Uh oh!
There was an error while loading. Please reload this page.
要求
注意事项
第一周题目
链表
简单:https://leetcode-cn.com/problems/remove-duplicates-from-sorted-list/
简单:https://leetcode-cn.com/problems/merge-two-sorted-lists
中等:https://leetcode-cn.com/problems/swap-nodes-in-pairs/
中等:https://leetcode-cn.com/problems/linked-list-cycle-ii
困难:https://leetcode-cn.com/problems/reverse-nodes-in-k-group/
数组
简单:https://leetcode-cn.com/problems/sort-array-by-parity/
简单:https://leetcode-cn.com/problems/sort-array-by-parity-ii/
中等:https://leetcode-cn.com/problems/search-in-rotated-sorted-array-ii/
中等:https://leetcode-cn.com/problems/find-minimum-in-rotated-sorted-array/
困难:https://leetcode-cn.com/problems/search-in-rotated-sorted-array
栈
简单:https://leetcode-cn.com/problems/valid-parentheses/
中等:https://leetcode-cn.com/problems/next-greater-element-ii/
困难:https://leetcode-cn.com/problems/maximum-frequency-stack/
递归
简单:https://leetcode-cn.com/problems/longest-univalue-path/
中等:https://leetcode-cn.com/problems/partition-to-k-equal-sum-subsets/
困难:https://leetcode-cn.com/problems/special-binary-string/
排序
简单:https://leetcode-cn.com/problems/valid-anagram/
中等:https://leetcode-cn.com/problems/wiggle-sort-ii/
困难:https://leetcode-cn.com/problems/maximum-gap/
二分查找
简单:https://leetcode-cn.com/problems/arranging-coins/
中等:https://leetcode-cn.com/problems/powx-n/
困难:https://leetcode-cn.com/problems/dungeon-game/
作业提交规则
The text was updated successfully, but these errors were encountered: