搜索结果
查询Tags标签: char,共有 1785条记录-
2 linux多进程开发-进程基础
进程状态 进程创建 父子进程 进程退出 孤儿进程、僵尸进程 wait | waitpid 1. 进程概述 程序和进程 程序是包含一系列信息的文件,这些信息描述了如何在运行时创建一个进程: 二进制格式标识:每个程序文件都包含用于描述可执行文件格式的元信息。内核利用此信息来解释文件…
2022/9/1 5:24:12 人评论 次浏览 -
C语言进阶语法及部分注意事项
目录0x00 计算机原理01 缓冲区(buffer)与缓存(cache)02 一个程序运行时的内存空间0x01 输入专题01 scanf02 sscanf0x02 文件专题01 fopen02 文本方式打开与二进制方式打开i. 区别ii. 如何读写iii. 判断末尾03 fseek 和 ftelli ftellii fseek0x03 变量专题01 extern02 cons…
2022/8/30 23:52:51 人评论 次浏览 -
Python 报错:json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
报错内容:json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)报错代码:print(res.json())报错原因:打印请求返回值报错 该接口返回值加密了
2022/8/29 1:25:05 人评论 次浏览 -
LeetCode 1347. Minimum Number of Steps to Make Two Strings Anagram
原题链接在这里:https://leetcode.com/problems/minimum-number-of-steps-to-make-two-strings-anagram/ 题目: You are given two strings of the same length s and t. In one step you can choose any character of t and replace it with another character. Return…
2022/8/28 23:53:48 人评论 次浏览 -
钓鱼攻击第一弹-释放文件
钓鱼攻击第一弹-释放文件 之后所有文章发至《熊猫安全》公众号上 获取当前路径 #include <stdio.h> #include "direct.h" #define MAX_SIZE 255 int main(int argc, const char* argv[]) {char buf[MAX_SIZE];getcwd(buf, sizeof(buf));printf("cur…
2022/8/28 23:27:40 人评论 次浏览 -
java中的字符流知识点总结
java中字符流 字符流:对文本的读取,速度比字节流快 常见的字符流:Reader 和 Writer Reader是InputStreamReader的父类,InputStreamReader是FileReader的父类 FileReader的相关方法: new FileReader(File/String) read:每次读取单个字符,返回该字符,如果到文件末尾返回…
2022/8/26 14:23:26 人评论 次浏览 -
文件IO-chdir-getcwd
getcwd#include <stdio.h> #include <stdlib.h> #include <unistd.h>#define MAX 512int main(int argc, char * argv[]) {// 方法一char path[MAX];path[0] = \0;getcwd(path, sizeof(path));puts(path);// 方法二char * buf = NULL;buf = getcwd(NULL…
2022/8/23 6:52:47 人评论 次浏览 -
C++ 黑客攻击系统
#include <iostream> #include <Windows.h> #include <string> #include <conio.h> //getch使用 #include "hacker.h" using namespace std;#define WIDTH 40 #define HEIGHT 15void inputPwd(char pwd[], int size) {char c;int i = …
2022/8/23 1:52:44 人评论 次浏览 -
python 简单密码校验
# 判断字符串长度是否在8位以上 def check_len(pwd):if len(pwd) >= 8:return Trueelse:return False# 检查字符串是否是有大小写字母、数字、其他符号组成 def check(pwd):# 初始化一个列表变量check = [0, 0, 0, 0]for char in pwd:# 如果字符是小写,将check[0]的值…
2022/8/22 1:25:50 人评论 次浏览 -
指针在内存所占的大小
sizeof的特点:printf(”%d“,int);printf(”%d“,float);printf(”%d“,double);其结果为4 4 4这就是面试的时候问你,指针在内存中占多少个字节?这就是个问题不是简单的2,4,甚至8个字节回答:指针在内存中所在的字节数是由系统的寻址能力决定的,寻址能力…
2022/8/21 5:56:18 人评论 次浏览 -
C++primer练习13.41-48
练习13.41 在push_back中我们为什么在construct调用后置递增 ::因为first_free指针就是第一个空闲位置,使用前置每次插入都会隔一个位置 练习13.42 在你的textQuery和Queryresult类中用strvec代替vector<string>进行测试 ::用StrVec替换vector<string>测…
2022/8/16 14:52:52 人评论 次浏览 -
c语言中输出整数类整型变量的长度(所占的字节数)
001、 c语言中整数类变量一共包含四个基本类型。 001、char型 002、 short int型 003、int型 004、long int型。 其中每种基本类型分为signed型 和 unsigned型, 也就是有符号型和无符号型, 但是有符号型和无符号型的长度是一样的。#include <stdio.h>in…
2022/8/16 6:23:13 人评论 次浏览 -
c语言中输出字符型变量(char型)所占用的位数
001、#include <stdio.h> #include <limits.h> ## CHAR_BIT定义了char型所占用的位数, 该变量定义在limits.h头文件中int main(void) {printf("CHAR_BIT = %d\n", CHAR_BIT);return 0; } 这说明,当前编译器中默认char型变量所占的位数为8.…
2022/8/16 6:23:11 人评论 次浏览 -
JAVA基础
//TreeSetTreeSet<Integer> set = new TreeSet<>();int n = in.nextInt();for(int i=0; i<n; i++){set.add(in.nextInt());}for(Integer a : set){System.out.println(a);}/*https://blog.csdn.net/Cricket_7/article/details/94430056 倒序 *///大数Strin…
2022/8/16 1:24:21 人评论 次浏览 -
第7章 函数——C++的编程模块
第7章 函数——C++的编程模块 7.8 编程练习题第1题#include <iostream> using namespace std;// 编写一个程序,不断要求用户输入两个数,直到其中的一个为0. // 对于两个数程序使用一个函数来计算它们的调和平均数,并将结果返回给main() // 调和平均数 = 2.0 * x…
2022/8/15 1:53:58 人评论 次浏览