Loading

12 2021 档案

摘要:💡💡💡 大概还有几个小时,2021年就彻底结束了,回望这一年感觉自己经历了不少事情。好好的回望过去,审视自己是为了让自己更好的前行。 🚩 关于学业 2021年整个上半年的重心都是毕业论文以及毕业答辩,倍感煎熬的三年研究生生活也画上了句号。从2020年11月份到2021年6月份,为了顺利毕业, 阅读全文
posted @ 2021-12-31 20:13 aalanwyr 阅读(74) 评论(0) 推荐(0)
摘要:Given the root of a binary tree, find the maximum value v for which there exist different nodes a and b where v = |a.val - b.val| and a is an ancestor 阅读全文
posted @ 2021-12-31 11:51 aalanwyr 阅读(67) 评论(0) 推荐(0)
摘要:Given a positive integer k, you need to find the length of the smallest positive integer n such that n is divisible by k, and n only contains the digi 阅读全文
posted @ 2021-12-30 15:23 aalanwyr 阅读(106) 评论(0) 推荐(0)
摘要:Given the head of a singly linked list, return the middle node of the linked list. If there are two middle nodes, return the second middle node. Examp 阅读全文
posted @ 2021-12-28 23:52 aalanwyr 阅读(79) 评论(0) 推荐(0)
摘要:Given a string s representing a valid expression, implement a basic calculator to evaluate it, and return the result of the evaluation. Note: You are  阅读全文
posted @ 2021-12-27 20:19 aalanwyr 阅读(58) 评论(0) 推荐(0)
摘要:Given a string s which represents an expression, evaluate this expression and return its value. The integer division should truncate toward zero. You 阅读全文
posted @ 2021-12-27 20:15 aalanwyr 阅读(63) 评论(0) 推荐(0)
摘要:The complement of an integer is the integer you get when you flip all the 0's to 1's and all the 1's to 0's in its binary representation. For example, 阅读全文
posted @ 2021-12-27 16:41 aalanwyr 阅读(67) 评论(0) 推荐(0)
摘要:Given an integer n, return true if it is a power of two. Otherwise, return false. An integer n is a power of two, if there exists an integer x such th 阅读全文
posted @ 2021-12-21 21:57 aalanwyr 阅读(52) 评论(0) 推荐(0)
摘要:起因:之前租了一个腾讯云服务器,每次登录的时候都会弹出一个warning,提示有很多failed login,也就是有很多主机尝试登录你的服务器。 1、查看有哪些主机尝试过登录你的服务器: [root@VM-4-12-centos ~]# lastb | head cirros ssh:notty 阅读全文
posted @ 2021-12-21 11:05 aalanwyr 阅读(1074) 评论(0) 推荐(0)
摘要:Given an encoded string, return its decoded string. The encoding rule is: k[encoded_string], where the encoded_string inside the square brackets is be 阅读全文
posted @ 2021-12-19 12:42 aalanwyr 阅读(95) 评论(0) 推荐(0)
摘要:Given an m x n binary matrix filled with 0's and 1's, find the largest square containing only 1's and return its area. Example 1: Input: matrix = [["1 阅读全文
posted @ 2021-12-17 16:24 aalanwyr 阅读(67) 评论(0) 推荐(0)
摘要:Given the head of a singly linked list, sort the list using insertion sort, and return the sorted list's head. The steps of the insertion sort algorit 阅读全文
posted @ 2021-12-15 16:57 aalanwyr 阅读(52) 评论(0) 推荐(0)
摘要:Given the root node of a binary search tree and two integers low and high, return the sum of values of all nodes with a value in the inclusive range [ 阅读全文
posted @ 2021-12-14 17:20 aalanwyr 阅读(56) 评论(0) 推荐(0)
摘要:The power of the string is the maximum length of a non-empty substring that contains only one unique character. Given a string s, return the power of  阅读全文
posted @ 2021-12-13 23:59 aalanwyr 阅读(94) 评论(0) 推荐(0)
摘要:A positive integer is magical if it is divisible by either a or b. Given the three integers n, a, and b, return the nth magical number. Since the answ 阅读全文
posted @ 2021-12-11 23:29 aalanwyr 阅读(61) 评论(0) 推荐(0)
摘要:Given an array of non-negative integers arr, you are initially positioned at start index of the array. When you are at index i, you can jump to i + ar 阅读全文
posted @ 2021-12-09 18:05 aalanwyr 阅读(64) 评论(0) 推荐(0)
摘要:1、什么是Embarrassingly Parallel(易并行计算问题) 易并行计算问题:A computation that can be divided into a number of completely independent tasks。在编写并行程序过程中,首先需要将一个问题分解成若 阅读全文
posted @ 2021-12-09 16:26 aalanwyr 阅读(2669) 评论(1) 推荐(1)
摘要:这篇帖子是对常用的平行计算问题方法的汇总,俗话说API好学,但是算法难用。除了需要了解常用的并行计算API(MPI、Pthread、openMP),更重要是要学会如何将串行问题(serial programming)进行合理的拆分,从而编写出能够并行计算的程序。 程序顺序执行、串行编写比较符合咱们的 阅读全文
posted @ 2021-12-09 13:11 aalanwyr 阅读(642) 评论(0) 推荐(0)
摘要:Given the root of a binary tree, return the sum of every tree node's tilt. The tilt of a tree node is the absolute difference between the sum of all l 阅读全文
posted @ 2021-12-09 00:20 aalanwyr 阅读(54) 评论(0) 推荐(0)
摘要:Given head which is a reference node to a singly-linked list. The value of each node in the linked list is either 0 or 1. The linked list holds the bi 阅读全文
posted @ 2021-12-07 23:09 aalanwyr 阅读(81) 评论(0) 推荐(0)
摘要:We have n chips, where the position of the ith chip is position[i]. We need to move all the chips to the same position. In one step, we can change the 阅读全文
posted @ 2021-12-06 23:39 aalanwyr 阅读(82) 评论(0) 推荐(0)
摘要:The thief has found himself a new place for his thievery again. There is only one entrance to this area, called root. Besides the root, each house has 阅读全文
posted @ 2021-12-05 11:42 aalanwyr 阅读(43) 评论(0) 推荐(0)
摘要:Given an integer array nums, find a contiguous non-empty subarray within the array that has the largest product, and return the product. It is guarant 阅读全文
posted @ 2021-12-05 00:15 aalanwyr 阅读(62) 评论(0) 推荐(0)
摘要:MPI 即 Message-Passing Interface,提供了一系列并行编程的接口,为了在本机能够学习和使用并行编程,需要提前安装MPI; 配置环境: Microsoft Visual Studio Community 2019 MPI 安装MPI: 1、首先下载MPI,这里需要下载两个文件 阅读全文
posted @ 2021-12-03 16:02 aalanwyr 阅读(2646) 评论(1) 推荐(0)
摘要:Given the head of a singly linked list, group all the nodes with odd indices together followed by the nodes with even indices, and return the reordere 阅读全文
posted @ 2021-12-02 15:58 aalanwyr 阅读(54) 评论(0) 推荐(0)
摘要:You are a professional robber planning to rob houses along a street. Each house has a certain amount of money stashed, the only constraint stopping yo 阅读全文
posted @ 2021-12-01 09:29 aalanwyr 阅读(59) 评论(0) 推荐(0)