上一页 1 ··· 4 5 6 7 8 9 下一页
摘要: 题目链接 https://leetcode-cn.com/problems/palindrome-linked-list/submissions/ 判断一个链表代表的数是否为回文数 1.将链表中的数字复制到数组中,再判断数组是否为回文数 这里不知道链表中有多少个结点,如果创建一个比较大的数组的话,又 阅读全文
posted @ 2021-06-19 18:39 SanFranciscoo 阅读(74) 评论(0) 推荐(0)
摘要: 题目链接: https://leetcode-cn.com/problems/add-two-numbers-ii/ 意思就是两个数字相加,但是这两个数字分别存在两个链表中,每个链表中的一个结点代表该数字的一位。 解法:利用栈,先将两个链表中的数字反向存入两个栈中,这样栈顶即为每个数字的末位(最低位 阅读全文
posted @ 2021-06-18 19:43 SanFranciscoo 阅读(78) 评论(0) 推荐(0)
摘要: 终端命令行中输入: xrandr 查看支持的分辨率,如下图所示: 使用 xrandr -s 1024x768 来调节分辨率,其中1024代表左右长度,768代表上下宽度,中间的是小写字母x 阅读全文
posted @ 2021-06-18 12:57 SanFranciscoo 阅读(113) 评论(0) 推荐(1)
摘要: 文章转载自: https://www.jianshu.com/p/37d0fd0fbbc1 ubuntu镜像iso文件地址:(需要FQ) http://mirrors.melbourne.co.uk/ubuntu-releases/ 首先,确保您已经安装或下载好VMware Workstation软 阅读全文
posted @ 2021-06-18 12:31 SanFranciscoo 阅读(501) 评论(0) 推荐(0)
摘要: 转载自: https://blog.csdn.net/thisway_diy/article/details/79207234 我的配置: vmware workstation pro 16,ubutun 18.04.1 一、为什么要让虚拟机中的Ubuntu上网?想在线安装软件,下载git源码包,或 阅读全文
posted @ 2021-06-18 11:29 SanFranciscoo 阅读(779) 评论(0) 推荐(0)
摘要: 转载、参考自: https://blog.csdn.net/S3132411278/article/details/117533063 https://blog.csdn.net/MMEHMY/article/details/107728549 1.下载vmware workstation16安装包 阅读全文
posted @ 2021-06-17 21:18 SanFranciscoo 阅读(329) 评论(0) 推荐(0)
摘要: 转自: https://blog.csdn.net/weixin_42592326/article/details/105930042 右击“我的电脑”,选择“管理”,选择“服务和应用程序”,选择“服务”,停掉这些服务 二、把注册表的vm目录给删了 windows+R,输入regedit 依次点开这 阅读全文
posted @ 2021-06-17 20:32 SanFranciscoo 阅读(500) 评论(0) 推荐(0)
摘要: 递归初步见: https://www.cnblogs.com/San-Francisco/p/14882647.html 题目: https://leetcode-cn.com/problems/swap-nodes-in-pairs/ 两两交换链表中的结点,分别用了1.递归 2.迭代 两个方法解决 阅读全文
posted @ 2021-06-15 15:19 SanFranciscoo 阅读(48) 评论(0) 推荐(0)
摘要: 题目链接如下: https://leetcode-cn.com/problems/remove-nth-node-from-end-of-list/ 本题使用了如下两个方法: 哑结点:若给定的链表中没有空的头节点,设置一个哑结点在第一个结点前面,最后在删除掉。 如: 题目中给定 head 作为链表的 阅读全文
posted @ 2021-06-15 13:49 SanFranciscoo 阅读(120) 评论(0) 推荐(0)
摘要: 空指针引用问题,最近经常遇到这个bug,找出了出现此bug的一个原因: 不能引用没有被赋值的指针。 例如: int *q=p->next; 要改为: if(p){ int *q=p->next; } 要使用指针p,必须保证p不为空指针。 更具体地,再举一个例子: #include <iostream 阅读全文
posted @ 2021-06-15 13:19 SanFranciscoo 阅读(775) 评论(0) 推荐(0)
上一页 1 ··· 4 5 6 7 8 9 下一页