原创 關於臺式機不帶休眠的問題 有可能是主板設置問題 以及 銘瑄刷BIOS fpart.txt找不到問題

我用的銘瑄的出名礦版B85 BTC(默認就是集顯輸出,我真是活久見,獨顯還得設置BIOS primary dispalaly) 如何設置都沒有休眠按鈕,然後鎖定是BIOS問題,看到有的人說是 BIOS 中ACPI 狀態找找S3,發現只有S

原创 PAT甲級1094 The Largest Generation (25分) 層序遍歷 vector嵌套來保存邊

1094 The Largest Generation (25分) A family hierarchy is usually presented by a pedigree tree where all the nodes on

原创 數據庫MySql python讀取插入數據,insert對那些類型加單引號,表單自己參考自己(外鍵),空值和NULL

今天做了下數據庫作業,好多出錯,記錄下,查漏補缺 本次只是實現一個employee表單,特殊在有一個外鍵參考自身主鍵,並且老師給的數據該外鍵可爲null 表結構直接用workbench 裏面構造的,Navicat還沒解決不修改密

原创 PAT甲級1106 Lowest Price in Supply Chain (25分) 雖然是簡單題,但是還是再捋下思路吧

1106 Lowest Price in Supply Chain (25分) A supply chain is a network of retailers(零售商), distributors(經銷商), and suppl

原创 PAT甲級1053 Path of Equal Weight (30分)

1053 Path of Equal Weight (30分) Given a non-empty tree with root R, and with weight W ​i ​​ assigned to each tree

原创 PAT甲級1155 Heap Paths (30分) 深搜

1155 Heap Paths (30分) In computer science, a heap is a specialized tree-based data structure that satisfies the hea

原创 PAT甲級1115 Counting Nodes in a BST (30分) 結構體 二叉樹 構造二叉搜索樹,層序遍歷,輸出每層節點個數

1115 Counting Nodes in a BST (30分) A Binary Search Tree (BST) is recursively defined as a binary tree which has the

原创 PAT甲級1107 Social Clusters (30分) 以及 牛客-並查集的實現 ,以及速度改進

目錄牛客並查集 先練練手,因爲有測試數據牛客並查集最初思路牛客並查集時間改進(可以直接看這個)PAT 牛客並查集 先練練手,因爲有測試數據 鏈接:https://www.nowcoder.com/questionTerminal/

原创 PAT甲級1154 Vertex Coloring (25分) 簡單題讀懂題目就好

1154 Vertex Coloring (25分) A proper vertex coloring is a labeling of the graph’s vertices with colors such that no

原创 PAT甲級1116 Come on! Lets C (20分) prime素數

1116 Come on! Let’s C (20分) “Let’s C” is a popular and fun programming contest hosted by the College of Computer Sc

原创 PAT甲級1140 Look-and-say Sequence (20分) 模擬

1140 Look-and-say Sequence (20分) Look-and-say sequence is a sequence of integers as the following: D, D1, D111, D11

原创 PAT甲級1145 Hashing - Average Search Time (25分) 平方探測法

注意:這裏說了探測只有正的探測,然後使用平方探測法、進行插入時,i的最大值爲size(table)-1 (也有部分說是size(table)/2,這裏倒是都能過了PAT的測試點);使用平方探測法進行查找時,i的最大值爲siz

原创 PAT甲級1105 Spiral Matrix (25分) 測試點分析 旋轉填充矩陣,做過很多次了

1105 Spiral Matrix (25分) This time your job is to fill a sequence of N positive integers into a spiral matrix in no

原创 PAT甲級 1130 Infix Expression (25分) 測試點2,中序遍歷添加額外條件

1130 Infix Expression (25分) Given a syntax tree (binary), you are supposed to output the corresponding infix expres

原创 PAT甲級1152 Google Recruitment (20分) 素數判斷

1152 Google Recruitment (20分) In July 2004, Google posted on a giant billboard along Highway 101 in Silicon Valley