
项目
hfkekxbhsjw
六年级新生
展开
-
一个简单的基于双缓冲区的控制台绘制类 C++实现
#include <stdio.h>#include <stdlib.h>#include <Windows.h>#include <vector>// 头文件class Drawer {private: char** frame_; HANDLE output, buffer; COORD coord = { 0,0 }; DWORD bytes = 0; int control_ = 0; // .原创 2022-04-01 17:42:21 · 584 阅读 · 2 评论 -
一个简单的矩阵运算类
#include <iostream>using namespace std;class Matrix{private: double mat_[4];public: Matrix(double num = 1); Matrix(double n1, double n2, double n3, double n4); friend ostream &operator<<(ostream &os, const Matrix.原创 2022-03-28 22:28:47 · 715 阅读 · 0 评论 -
一个小Library类
#include <vector>#include <unordered_map>#include <string>#include <cstring>#include <regex>#include <exception>#include <iostream>using namespace std;// 输入格式错误异常类class FormatError {public: FormatError.原创 2022-03-13 10:34:03 · 269 阅读 · 0 评论 -
Python selenium+cookie实现免密登陆
今天爬取airbnb的租房数据时,遇到了登陆问题。自己动手解决了一下。我们知道,http是无状态的,那么网页如何实现用户登陆注册功能呢?Session和Cookie就是为了满足这种需求出现的技术。首先介绍一下Session和Cookie的概念。在Web中Session对象存储特定用户会话所需的属性及配置信息。这样,当用户在应用程序的Web页之间跳转时,存储在Session对象中的变量将不会丢失,而是在整个用户会话中一直存在下去。当用户请求来自应用程序的 Web页时,如果该用户还没有会话,则Web原创 2022-02-21 09:36:59 · 6361 阅读 · 8 评论 -
一个简单的bing图片爬虫
# -*- coding: utf-8 -*-# 作者:ERicimport reimport osfrom time import sleepfrom bs4 import BeautifulSoupfrom msedge.selenium_tools import Edge, EdgeOptionsfrom funcs import url_funcsglobal keyword, pic_num, base_urltags = []keyword = input('请输入关键.原创 2022-02-07 17:23:10 · 932 阅读 · 0 评论 -
C语言实现的图书管理系统(管理员端)
因为C语言内部只有一个非常原始的数组数据结构,所以我考虑了很久到底要怎么存储书籍信息。。最后的方案是维护一个伪动态数组,维护一个指针,指向数组末位元素。增加元素时,直接覆盖掉指针后一位,并且指针自增。要注意数组越界问题。删除元素时,将目标删除元素和末位元素交换位置,然后指针自减。除此之外,为了实现模糊查找,用了KMP模式匹配算法。但是最让我满意的还是,写代码过程中,我两三分钟手撕了快速排序~~~//图书馆管理系统管理员端#define _CRT_SECURE_NO_WARNING原创 2021-11-25 17:46:06 · 2605 阅读 · 0 评论 -
Python实现的任务管理助手
import os#storagevalidlist = []#有效任务队列tasks = {}#当前任务-优先级rank = []#当前已排序任务#当前任务列currentlist = "study"########内存--外部存储连接函数def get_data(filename,saver):#从filename中向saver写入数据 if type(saver) == dict: file = open("Storage\\"+filename+".t.原创 2021-11-04 21:21:40 · 189 阅读 · 0 评论 -
贪吃蛇贪吃蛇贪吃蛇贪吃蛇
给好盆友@cgy @hxf写的~大概应该可能没有用C++特有的语法吧。。#include <conio.h>#include <windows.h>#include <ctime>#include <cstdlib>using namespace std;struct pos {//坐标点 int x;//列 int y;//行};const int X = 35;const int Y = 18;char sc原创 2021-11-01 18:51:12 · 509 阅读 · 3 评论 -
无聊的大数
#include <iostream>#include <string>#include <cmath>using namespace std;string turn_str(int num){ string str = ""; int flag = bool(num < 0); if (flag)num = -num; while (num / 10) { str = char(num % 10 .原创 2021-10-09 20:12:51 · 108 阅读 · 0 评论