自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(27)
  • 收藏
  • 关注

原创 在wsl中使用 code . 打开vscode所遇到的各种问题

在wsl中使用code . 打开vscode自己遇到的各种问题zsh: command not found: codePermission denied

2021-12-28 23:11:03 10441 6

原创 WSL2 参考的对象类型不支持尝试的操作

启动wsl2的时候出现了参考的对象类型不支持尝试的操作原因是加速器的端口和wsl冲突了把uu加速器关掉就好起来了(;´д`)ゞ参考的对象类型不支持尝试的操作。 #4194 https://github.com/microsoft/WSL/issues/4194 ...

2021-12-18 00:23:16 716

原创 汉明重量 统计二进制位中1的数量 variable-precision SWAR

在操作系统实验中遇到了位图统计的问题,了解到了汉明重量的相关。以下是处理32位长度的数组int count_bit(int n){ register int x = n; x = (x & 0x55555555) + ((x >> 1) & 0x55555555); x = (x & 0x33333333) + ((x >> 2) & 0x33333333); x = (x & 0x0f0f0f0f) +

2021-12-07 19:17:48 275

原创 git push 遇到 error: cannot update the ref ‘refs/remotes/origin/master‘: Permission denied

在昨天晚上就git push之后毫无反应,连报错都无,一顿操作毫无变化于是就放弃了去睡觉。今天起床之后再次尝试,怎么说呢,还算是变好了,至少有报错了= =根据各种博客尝试了一遍。rm -rf .git/refs/remotes/origin mkdir .git/refs/remotes/origin 之后仍然报一样的错误。在尝试git gc --prune=now这句之后就好起来了,虽然这句昨晚也有尝试过。总之就是奇怪地解决了。...

2021-12-03 12:34:17 3208

原创 ssh: connect to host ubuntu port 22: Connection timed out

在vscode里面通过ssh连接虚拟机的时候提示”过程试图写入的管道不存在”情况是:Windows可以ping到虚拟机,虚拟机也可以自己ssh上自己。也通过service sshd status 检查过虚拟机这边的服务是开着的。中间甚至重装了vscode的remote-ssh插件最后通过sudo ufw allow sshsudo ufw allow 22sudo ufw enablesudo ufw status就搞定了。...

2021-11-25 22:30:54 2514 1

原创 【MPI】PMPI_Send(100): Invalid rank has value 5 but must be nonnegative and less than 4

记录一下自己的愚蠢行为。copy了别人的代码结果遇到了这个问题,搜索了一番没有发现答案。最后自己根据错误提示看出来了。代码中的MPI_Send的dest的进程地址超出了已创建的进程。如图所示 ↓总结:就是说还是要老老实实自己写代码...

2021-11-23 10:25:53 876 1

原创 vs2019缺失graphics.h头文件的解决办法

前往 https://easyx.cn/ ,点击右侧按钮下载EasyX。点开安装程序,下一步,来到图示,安装检测到的版本弹出窗口显示安装成功,在vs2019中引入#include <graphics.h>不会报错

2021-08-20 18:01:22 3530 1

原创 基于JAVA的简单扫雷

先放上最后的效果图:做了右键插旗和右键自动打开周围方格,但没做右键两次插问号,毕竟我自己扫雷也不太经常用问号,干脆就不做了.遇到的问题没有很多:最后有github链接.界面设计上面的剩余数量,时间和用于重新开始的笑脸按钮:扫雷区域:数据结构 //用一个二位数组来和JButton二维数组对应,存储雷的数据 Mine[][] mines=new Mine[ROW][COL]; JButton[][] btns=new JButton[ROW][COL];

2021-01-27 21:45:22 444 1

原创 怎么给新版edge换皮肤外观?| 出现清单文件丢失或不可读取如何解决

文章目录1. 在Chrome浏览器中的操作2. 在edge浏览器中的操作3. 如果出现”清单文件丢失或不可读取“的解决办法因为新版edge的主题在一开始只有默认的三个选项可以用,从五彩斑斓的Chrome过来的我十分不适应,虽然说edge可以直接添加大部分chrome商店里的插件,但是皮肤是不行的。以下为edge如何更换Chrome的皮肤,并且偶尔会出现“清单文件丢失或不可读取”如何解决的办法。1. 在Chrome浏览器中的操作1.1 进入谷歌应用商店的主题背景选择界面,地址如下:https://c

2020-07-20 13:24:19 3302 1

原创 UVA - 424 Integer Inquiry

One of the first users of BIT’s new supercomputer was Chip Diller. He extended his exploration ofpowers of 3 to go from 0 to 333 and he explored taking various sums of those numbers.“This supercompu...

2019-01-27 21:32:36 150

原创 POJ - 3087 Shuffle'm Up

A common pastime for poker players at a poker table is to shuffle stacks of chips. Shuffling chips is performed by starting with two stacks of poker chips, S1 and S2, each stack containing C chips. E...

2019-01-26 23:47:38 109

原创 HDU - 1213 How Many Tables

Today is Ignatius’ birthday. He invites a lot of friends. Now it’s dinner time. Ignatius wants to know how many tables he needs at least. You have to notice that not all the friends know each other, ...

2019-01-26 17:42:41 124

原创 HDU - 1241 Oil Deposits

The GeoSurvComp geologic survey company is responsible for detecting underground oil deposits. GeoSurvComp works with one large rectangular region of land at a time, and creates a grid that divides t...

2019-01-26 17:05:34 130

原创 POJ - 1611 The Suspects

Severe acute respiratory syndrome (SARS), an atypical pneumonia of unknown aetiology, was recognized as a global threat in mid-March 2003. To minimize transmission to others, the best strategy is to ...

2019-01-26 16:59:46 139

原创 HDU-2099 整除的尾数

Problem Description一个整数,只知道前几位,不知道末二位,被另一个整数除尽了,那么该数的末二位该是什么呢?Input输入数据有若干组,每组数据包含二个整数a,b(0&lt;a&lt;10000, 10&lt;b&lt;100),若遇到0 0则处理结束。Output对应每组数据,将满足条件的所有尾数在一行内输出,格式见样本输出。同组数据的输出,其每个尾数之间空一...

2018-12-13 21:10:30 158

原创 HDU-1049 Climbing Worm

Problem DescriptionAn inch worm is at the bottom of a well n inches deep. It has enough energy to climb u inches every minute, but then has to rest a minute before climbing again. During the rest, i...

2018-12-13 19:52:29 139

原创 HDU-1284 钱币兑换问题

在一个国家仅有1分,2分,3分硬币,将钱N兑换成硬币有很多种兑法。请你编程序计算出共有多少种兑法。Input每行只有一个正整数N,N小于32768。Output对应每个输入,输出兑换方法数。Sample Input293412553Sample Output71883113137761问题链接:http://acm.hdu.edu.cn/showprobl...

2018-12-13 19:42:43 437

原创 HDU-2027 第一次周赛Problem I

统计每个元音字母在字符串中出现的次数。Input输入数据首先包括一个整数n,表示测试实例的个数,然后是n行长度不超过100的字符串。Output对于每个测试实例输出5行,格式如下:a:num1e:num2i:num3o:num4u:num5多个测试实例之间由一个空行隔开。请特别注意:最后一块输出后面没有空行:)Sample Input2aeioumy n...

2018-12-09 22:55:24 131

原创 CodeForces - 515A 第一次周赛Problem H

Someday, Drazil wanted to go on date with Varda. Drazil and Varda live on Cartesian plane. Drazil’s home is located in point (0, 0) and Varda’s home is located in point (a, b). In each step, he can m...

2018-12-09 22:45:05 146

原创 HDU - 2039 第一次周赛Problem D

给定三条边,请你判断一下能不能组成一个三角形。Input输入数据第一行包含一个数M,接下有M行,每行一个实例,包含三个正数A,B,C。其中A,B,C &lt;1000;Output对于每个测试实例,如果三条边长A,B,C能组成三角形的话,输出YES,否则NO。Sample Input21 2 32 2 2Sample OutputNOYES题目解析:题...

2018-12-09 22:39:32 145

原创 CodeForces - 4A 第一次周赛Problem A

One hot summer day Pete and his friend Billy decided to buy a watermelon. They chose the biggest and the ripest one, in their opinion. After that the watermelon was weighed, and the scales showed w k...

2018-12-09 22:32:27 111

原创 CodeForces-118A String Task

Petya started to attend programming lessons. On the first lesson his task was to write a simple program. The program was supposed to do the following: in the given string, consisting if uppercase and...

2018-12-07 21:48:20 150

原创 CodeForces - 266A Stones on the Table

There are n stones on the table in a row, each of them can be red, green or blue. Count the minimum number of stones to take from the table so that any two neighboring stones had different colors. St...

2018-12-07 21:03:54 82

原创 HDU-1000 A + B Problem

Calculate A + B.InputEach line will contain two integers A and B. Process to end of file.OutputFor each case, output A + B in one line.Sample Input1 1Sample Output2题目解析:主要就是循环输入和输出,...

2018-12-07 20:57:04 227

原创 HDU-2000 ASCII码排序

输入三个字符后,按各字符的ASCII码从小到大的顺序输出这三个字符。Input输入数据有多组,每组占一行,有三个字符组成,之间无空格。Output对于每组输入数据,输出一行,字符中间用一个空格分开。Sample InputqweasdzxcSample Outpute q wa d sc x z题目解析:按照ASCII码排序,因为只有三个字符所以可以1...

2018-12-07 20:54:40 186

原创 HDU-2002 计算球体积

根据输入的半径值,计算球的体积。Input输入数据有多组,每组占一行,每行包括一个实数,表示球的半径。Output输出对应的球的体积,对于每组输入数据,输出一行,计算结果保留三位小数。Sample Input11.5Sample Output4.1894.137Hint#define PI 3.1415927题目解析:用while实现多次输入输出...

2018-12-07 20:48:21 111

原创 HDU-2101 A + B Problem Too

This problem is also a A + B problem,but it has a little difference,you should determine does (a+b) could be divided with 86.For example ,if (A+B)=98,you should output no for result.InputEach lin...

2018-12-07 20:34:37 192

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除