- 博客(36)
- 问答 (1)
- 收藏
- 关注
原创 如何理解自然连接和等值连接
等值连接和自然连接是关系数据库中两种不同的表连接方式,它们在连接表时的要求和行为上有所不同,下面将通过具体的例子来解释这两个概念。
2024-05-15 10:39:53
2247
原创 二叉排序树——每个节点的左子树中的键值小于节点的键值,右子树中的键值大于节点的键值
要确定查找元素30在二叉排序树中需要进行多少次比较,首先需要根据给定的序列建立二叉排序树。序列是:50,72,43,85,75,20,35,45,65,30。利用逐点插入建立序列(50,72,43,85,75,20,35,45,65,30)对应的二叉排序树以后,要查找元素 30 要进行几次元素间的比较?左子树中的所有节点的键都小于节点X的键。右子树中的所有节点的键都大于节点X的键。因此,总共进行了5次比较。
2024-04-18 16:47:07
422
原创 计算机网络—RTT-RTTS-RTTD和RTO的解释及例题讲解
传输控制协议(TCP,Transmission Control Protocol)是一种面向连接的、可靠的、基于字节流的传输层通信协议。 本文解释关于网络通信效率的几个术语:RTT,RTTS,RTTD和RTO及讲解例题。如有问题,欢迎批评指正。
2024-04-12 12:50:30
4112
2
原创 切莫混淆模2除法(亦称异或除法,特别应用在计算CRC循环冗余校验)和传统的二进制除法
在和ChatGPT4.0沟通时,发现其在回答“模2除法题目时”出现错误答案,特整理“模2除法”和“普通二进制除法”的内容,以防混淆。
2024-04-11 15:34:22
2411
原创 与ChatGPT4.0互动:从路人视角了解什么是比特币Bitcoin
与ChatGPT4.0一问一答,从普通人的角度去了解什么是比特币,什么是挖矿,为什么有人炒作比特币等问题。
2024-04-09 11:19:58
1172
原创 GBase8a-GDCA认证考试-复习参考题
为提升产品服务水平定期举办GBase产品认证培训,培训更多GBase数据库专业人员,满足用户快速成长的业务需求,建设GBase产品生态。请注意甄别,根据所学知识综合判断,正确率97%(97分)。
2024-03-27 15:26:12
1356
原创 南大通用GBase 8c 多模多态分布式数据库系列二之安装与卸载
感谢南大通用提供的GBase 8c GDCA 认证培训课程。本系列旨在记录学习心得和分享传播国产分布式数据库。此章目的是:了解 GBase 8c 分布式数据库架构,熟悉分布式部署流程、掌握分布式集群的安装和卸载操作
2023-06-18 14:53:06
2170
1
原创 南大通用GBase 8c 多模多态分布式数据库系列一之基本介绍、核心技术、架构演进
随着传统的关系型SQL数据库(Oracle,MySQL,PostgreSQL等)难以满足日益增长的高数据量、快速数据处理要求、高数据库安全及强容灾能力要求(RPO,RTO)等挑战,尽管NoSQL非关系型数据库以非结构化、数据格式灵活、无通用SQL语言、使用API、支持PB级存储等优势而一跃而上。
2023-06-12 21:43:10
3973
原创 如何拿到美国软件工程师Offer及程序员体验
今天,我从记忆里挑出了一段很重要的片段:毕业后成为软件工程师。分享给各位读者,我们一起来从这段经历里探索:我(留学生)是如何找到工作的?在美国当程序员是种什么体验?是否和国内的“程序猿”们有明显的区别?是否存在996和可怕的加班文化?
2023-02-10 16:39:04
1551
3
原创 Swift刷LeetCode 之 384-Shuffle an Array-Med
题目:Given an integer arraynums, design an algorithm to randomly shuffle the array.Implement theSolutionclass:Solution(int[] nums)Initializes the object with the integer array nums. int[] reset()Resets the array to its original configuration and ...
2021-05-09 03:34:14
147
原创 Swift刷LeetCode 之 395-Longest Substring with At Least K Repeating Characters-Med
Given a stringsand an integerk, returnthe length of the longest substring ofssuch that the frequency of each character in this substring is greater than or equal tok.返回一个包含最长,且每个字母至少出现k次的substring。Example 1:Input: s = "aaabb", k = 3Output: 3...
2021-05-01 05:27:23
165
1
原创 Swift刷LeetCode 之 1833-Maximum Ice Cream Bars-Med
It is a sweltering summer day, and a boy wants to buy some ice cream bars.At the store, there arenice cream bars. You are given an arraycostsof lengthn, wherecosts[i]is the price of theithice cream bar in coins. The boy initially hascoinscoins...
2021-04-25 10:01:46
238
原创 Swift刷LeetCode 之 1832-Check if the Sentence Is Pangram-Easy
Apangramis a sentence where every letter of the English alphabet appears at least once.pangram指至少包含26个英文字母的句子。Given a stringsentencecontaining only lowercase English letters, returntrueifsentenceis apangram, orfalseotherwise.Example 1:I...
2021-04-25 09:29:16
241
原创 Swift刷LeetCode 之 877-Stone Game-Med
Alex and Lee play a game with piles of stones. There are an even number ofpilesarranged in a row, and each pile has a positive integer number of stonespiles[i].The objective of the game is to end with the moststones. The total number of stones is o...
2020-09-20 10:53:20
416
原创 Swift刷LeetCode 之 1561-Maximum Number of Coins You Can Get-Med
There are 3npiles of coins ofvarying size, you and your friends will take piles of coins as follows:In each step, you will chooseany3 piles of coins (not necessarily consecutive). Of your choice,Alicewill pickthe pile with the maximum number of c...
2020-08-27 00:24:25
265
原创 Swift刷LeetCode 之 1539-Kth Missing Positive Number-Easy
Given an arrayarrof positive integerssorted in astrictly increasing order, and an integerk.Find thekthpositive integer that is missing from this array.给定一个按严格递增顺序排序的正整数数组arr和一个整数k。找出这个数组中丢失的第k个正整数。Example 1:Input: arr = [2,3,4,7,11], k...
2020-08-24 12:16:03
272
原创 Swift刷LeetCode 之 1544-Make The String Great-Easy
Given a stringsof lower and upper case English letters.A good string is a string which doesn't havetwo adjacent characterss[i]ands[i + 1]where:0 <= i <= s.length - 2 s[i]is a lower-case letter ands[i + 1]is the same letter but in upper...
2020-08-20 10:26:40
322
原创 UINavigationBar在iOS13中的变化
苹果iOS13在外观上做了很多改变,导航栏就是其中之一。什么改变了?在iOS13中,大标题风格导航栏的默认外观已经从半透明变成透明。 在普通样式的表视图中没有什么变化,导航栏将显示表视图的颜色,在本例中是白色。对于分组样式,也有一些抵消性的更改。 这些变化并不大,但如果你的设计依赖于这个彩色条,你可能需要调整你的设计或添加一些代码回到旧的外观风格。如何回到老样子?如果你想要半透明...
2020-08-20 03:19:51
1476
原创 iOS/Xcode问题之Command CodeSign failed with a nonzero exit code或者Revoke certificate
如果你也经历了类似的错误,可以尝试用我的方法看是否解决。错误例图如下根据我的经验,造成这个问题的原因是我错误地将钥匙链访问权限重置为默认,所以我丢失了我的开发证书。 我怎么解决这个问题? 我从钥匙链访问(Keychain Access)中清理了我的苹果开发证书 我Keychain Access清理了我的苹果开发private密钥 然后我得到了新的错误: Revoke certificate Your account already has an Apple Development sig
2020-08-20 00:47:31
4003
原创 Swift刷LeetCode 之 1550-Three Consecutive Odds-Easy
Given an integer arrayarr, returntrueif there are three consecutive odd numbers in the array. Otherwise, returnfalse.给定一个整数数组arr,如果数组中有三个连续的奇数,则返回true。否则,返回false。Example 1:Input: arr = [2,6,4,1]Output: falseExplanation: There are no three cons...
2020-08-19 10:56:01
234
原创 Swift刷LeetCode 之 14-Longest Common Prefix-Easy
Write a function to find the longest common prefix string amongst an array of strings.If there is no common prefix, return an empty string"".编写一个函数来查找字符串数组中最长的公共前缀字符串。如果没有公共前缀,返回一个空字符串""。Example 1:Input: ["flower","flow","flight"]Output: "fl".
2020-08-19 10:38:00
159
原创 Swift刷LeetCode 之 4-Median of Two Sorted Arrays-Hard
There are two sorted arraysnums1andnums2of size m and n respectively.Find the median of the two sorted arrays. The overall run time complexity should be O(log (m+n)).You may assumenums1andnums2cannot be both empty.有两个大小分别为m和n的编号为s1和编号为s2的排序数组...
2020-08-18 11:47:16
209
原创 Swift刷LeetCode 之 9- Palindrome Number-Easy
Determine whether an integer is a palindrome. An integerisapalindrome when itreads the same backward as forward.确定一个整数是否是回文。一个整数是一个回文,当它读取相同的向后和向前。Example 1:Input: 121Output: trueExample 2:Input: -121Output: falseExplanation: From left ...
2020-08-18 10:40:20
212
原创 Swift刷LeetCode 之 7- Reverse Intege-Easy
Given a 32-bit signed integer, reverse digits of an integer.给定一个32位有符号整数,整数的反向数字。Example 1:Input: 123Output: 321Example 2:Input: -123Output: -321Example 3:Input: 120Output: 21Note:Assume we are dealing with an environment which co
2020-08-17 11:25:59
269
原创 Swift刷LeetCode 之 3- Longest Substring Without Repeating Characters-Med
Given a string, find the length of thelongest substringwithout repeating characters.给定一个字符串,查找不重复字符的最长子字符串的长度。Example 1:Input: "abcabcbb"Output: 3 Explanation: The answer is "abc", with the length of 3. Example 2:Input: "bbbbb"Output: 1Ex..
2020-08-17 10:29:36
225
原创 Swift刷LeetCode 之 2-Add Two Numbers-Med
Given给定* public class ListNode {* public var val: Int* public var next: ListNode?* public init() { self.val = 0; self.next = nil; }* public init(_ val: Int) { self.val = val; self.next = nil; }* public init(_ val: Int, _ ...
2020-08-15 01:01:55
243
原创 Swift刷LeetCode 之 1-Two Sum-Easy
Given an array of integers, returnindicesof the two numbers such that they add up to a specific target.给定一个整数数组,返回两个数字的索引,使它们加起来成为一个特定的目标。You may assume that each input would haveexactlyone solution, and you may not use thesameelement twice.您可能...
2020-08-14 12:56:42
218
原创 View生命周期之viewWill/DidAppear(), viewWill/DidDissappear() &解决问题Fatal error: Unexpectedly found nil
viewDidLoad() -> viewWillAppear() -> viewDidAppear() -> viewWillDissappear() -> viewDidDisappear() 有ViewController1和ViewController2.两个关系如下,点击click, view1 -> view2, 点击back, view2 -> ...
2020-03-16 01:00:48
2872
原创 navigationController.pushViewController(viewController: UIViewController, animated: Bool) 不起作用
本人仅适合于用纯代码去写程序,不用于Storyboard.不用Storyboard, 用纯代码写app,一般来说,如果我们想从ViewControllerA跳转到另外一个ViewController B,会用到navigationController.pushViewController(),但对于新手来说,有时候此函数不起作用,是因为我们的A和B应当被嵌入/装入进我们的Navigat...
2020-02-05 08:21:50
1345
原创 使用Firebase, observe 和 observeSingleEvent的区别
Firebase Realtime数据库是一个NoSQL数据库,可以用来存储和检索我们的应用程序的数据。数据存储为JSON,整个数据库可以看作是一个巨大的JSON树。数据写在由相对路径(关联键)定义的特定位置,可以使用相同的路径检索。随着数据被添加到JSON树中,它将成为现有JSON结构中的一个节点。使用DatabaseReference的observe(_:with)或obs...
2020-01-29 01:59:09
330
原创 不用storyboard创建新项目之SceneDelegate.swift (Xcode 11 & IOS 13)
如果是在Xcode11 & IOS 13之前,如果不用storyboard创建新项目,一般是在appDelegate.swift中,例子如下,我们简单的创建一个SearchBar用UINavigationController。现在,有一些小改变,sceneDelegate.swift相比于appDelegate.swift,更像是一个top-level UI object,所...
2019-12-31 02:02:45
2097
1
原创 为什么要用Github以及如何注册和使用Github去Push项目到Repository
GitHub GitHub是由Linux系统所创建的工具,名为git,由创建Linux本身的人Linus Torvalds。对于无论是开发人员还是使用开源软件的人。,它是开源软件的自动供应链。Github更像是一个集市,而集市内的摆摊者-就是程序员,算法分析师,数据分析师等有好想法和需要合作的人。一个好汉三个帮,GitHub既可以是一个小范围组织或个人的工作场所,也是一个具有各种open sour...
2018-07-11 09:20:01
640
原创 Python module(模块安装问题)No module named "XXX" (比如numpy,等等)
Python最强大的功能之一在于对与模块的兼容性,这也导致了尽管Python属于相对“简单”语言,但因兼容各种功能性模块,使得Python可以完成众多任务,因此Python又被称为胶水语言(能够把其他语言制作的模块融合为自己所用)。 对于一个新安装的Python软件来说,除了基本库,是没有其他功能的,在导入我们需要库的时候会提示No module named "XXX"。如何解决...
2018-07-09 11:10:57
51392
1
翻译 Python和Machine Learning之 Pycharm软件:Cannot import name 'mpl' from 'matplotlib'
Pycharm软件在安装之初并没有导入我们所需module(模块),如果我们想用matplotlib模块并已经从相应网站成功下载,安装,导入到软件里。在使用from matplotlib import mpl去导入在project里,会出现如下错误: ...
2018-07-09 10:43:52
4080
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人