原创 Ubuntu更換源

sudo cp /etc/apt/sources.list /etc/apt/sources.list.bak //備份 sudo gedit /etc/apt/sources.list //編輯 //粘貼以下內容 deb

原创 Ubuntu更換系統字體

一、下載字體 瀏覽器輸入http://www.mycode.net.cn/wp-content/uploads/2015/07/YaHeiConsolas.tar.gz 二、【字體安裝】 1.  解壓壓縮包 tar -zxvf YaHei

原创 單鏈表創建及增刪改查銷燬(新版)

#include<iostream> #include<stdlib.h> using namespace std; #define error -1 /* create and operate a list with a head

原创 單鏈表升序合併和降序合併(新版)

#include <iostream> #include<stdlib.h> using namespace std; typedef struct Lnode { int data; Lnode *next; } L

原创 線性表增刪改查(新版)

#include <iostream> using namespace std; #define maxSize 100 #define error -1 typedef struct { int data[maxSize];

原创 Python爬蟲之獲取小說

學這個之前請確保自己對http協議和html有些瞭解(不用全都會) 爬蟲是什麼? 爬蟲就是模擬瀏覽器去訪問鏈接,來幫助我們獲取想要的數據,可見即可爬(爬不到就是技術不夠) 瀏覽器是怎樣訪問網頁的呢? 瀏覽器會向一個網站發起一個請求,網站再

原创 python爬蟲之開發工具篇-Pycharm

聲明:有的圖是用的別人的圖,這些軟件我懶得再重裝一遍 一:Python安裝 寫Python爬蟲,第一步當然要安裝Python啦! 不囉嗦,Python下載鏈接在此:https://www.python.org/downloads/   (

原创 Eclipse 連接數據庫報錯 時區錯誤

Eclipse 連接數據庫報錯 時區錯誤 java.sql.SQLException: The server time zone value 'Öйú±ê×¼Ê 解決:在原來的參數“url”後面,拼上這個字符串:?serverTimez

原创 有重複元素的排列

#include<stdio.h> #include<string.h> int count=0; void swap(char &a,char &b) { char temp; temp=a; a=b; b=temp; } i

原创 最大間隙問題

#include <stdio.h> #define INF 1<<30 struct node{ double left,right; double max=-INF,min=INF; int index=0; }x[105];

原创 衆數問題

#include <iostream> #include <cstdio> using namespace std; // 本程序的關鍵。 以中間的數字爲界限。 確定左右起始和終止界限 void split(int s[], int

原创 馬的問題

#include "iostream" #include "iomanip" #include "cstdlib" using namespace std; int board[100][100]; int dx[8] = {-2,

原创 排列的字典序

#include<iostream> #include<cstdlib> #include<cstdio> #include<algorithm> using namespace std; long long a[14],j[15]=

原创 最多約數問題

最多約數問題。正整數x 的約數是能整除x的正整數,其約數的個數記爲div(x),例如div(10)=4。設a 和b 是兩個正整數,找出a 和b 之間約數個數最多的數x 的約數個數。 樣例輸入:   136 樣例輸出:   9 #incl

原创 數字統計問題

題解主要來自https://blog.csdn.net/m0_37579232/article/details/79651307 ★問題描述:一本書的頁碼從自然數1開始順序編碼直到自然數n。書的頁碼按照通常的習慣編排,每個頁碼都不含多餘的