\(\text{Problem}:\)题目链接 \(\text{Solution}:\) 非常巧妙的一道全局思维题。与 CF1375G 有着异曲同工之妙。 此处引入一种势能函数。设当前状态为 \(S\),存在一个函数 \(F(S)\),使得每次操作可以使得 \(F(S)\) 的期望增加 \(1\), ...
分类:
其他好文 时间:
2021-02-25 11:40:20
阅读次数:
0
Given a string s of lower and upper case English letters. A good string is a string which doesn't have two adjacent characters s[i] and s[i + 1] where ...
分类:
其他好文 时间:
2021-02-22 12:38:24
阅读次数:
0
方式1:js代码,延迟2秒后跳转到首页 <script> setTimeout(function () { location.href = '/'; }, 2000);</script> 方式2:利用响应头部进行重定向 response = make_response('注销并进行重定向', 302 ...
分类:
其他好文 时间:
2021-02-22 12:34:44
阅读次数:
0
cat car.py 1 #! /usr/bin/python 2 # -*- coding:utf-8 -*- 3 4 5 class Car(object): 6 """ 7 模拟汽车 8 """ 9 def __init__(self, make, model, year): 10 """初始 ...
分类:
其他好文 时间:
2021-02-19 13:20:12
阅读次数:
0
#!/bin/bashyum install -y readline-devel ncurses-develyum install -y vim make telnet lsof tree rdate ntp gcc gcc-c++ psmisc net-tools \screen expect s ...
分类:
系统相关 时间:
2021-02-18 13:45:26
阅读次数:
0
为什么要使用make 先来想像一个案例,假设我的可执行文件里面包含了四个源代码文件,分别是 main.c haha.c sin_value.c cos_value.c 这四个文件,这四个文件的目的是: main.c :主要的目的是让使用者输入角度数据与调用其他三支副程序; haha.c :输出一堆有 ...
分类:
其他好文 时间:
2021-02-18 13:38:45
阅读次数:
0
一、题目描述 给定一个数组 nums 和滑动窗口的大小 k,请找出所有滑动窗口里的最大值。 示例: 输入: nums = [1,3,-1,-3,5,3,6,7], 和 k = 3输出: [3,3,5,5,6,7] 解释: 滑动窗口的位置 最大值 [1 3 -1] -3 5 3 6 7 3 1 [3 ...
分类:
其他好文 时间:
2021-02-18 13:06:38
阅读次数:
0
常用环境配置 要清理磁盘空间可以看这个文章:https://www.linuxprobe.com/disk-release.html 最简单的安装,结束以后先换源 apt install build-essential gcc make perl dkms # 之后安装vbox增强功能 # 基本工具 ...
分类:
系统相关 时间:
2021-02-17 15:13:48
阅读次数:
0
编号349:两个数组的交集 给定两个数组,编写一个函数来计算它们的交集。 示例 1: 输入:nums1 = [1,2,2,1], nums2 = [2,2] 输出:[2] 示例 2: 输入:nums1 = [4,9,5], nums2 = [9,4,9,8,4] 输出:[9,4] 说明: 输出结果中 ...
分类:
编程语言 时间:
2021-02-17 14:05:05
阅读次数:
0
Problem A Right-Coupled Numbers 留坑。 Problem B Make Numbers 留坑。 Problem C Pyramid 留坑。 Problem D Quality Monitoring 留坑。 Problem E A Color Game 留坑。 Probl ...
分类:
其他好文 时间:
2021-02-16 12:17:48
阅读次数:
0