#include<iostream>
#include<stdio.h>
using namespace std;
int main(){
if(freopen("bus.in","r",stdin)==NULL)
printf("error while opening input file.\n");
if(freopen("bus.out","w",stdout)==NULL)
printf("error while opening output file.\n");
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 编辑/etc/default/grub文件: | |
| GRUB_CMDLINE_LINUX参数加上ipv6.disable=1 | |
| 以root运行命令: | |
| grub2-mkconfig -o /boot/grub2/grub.cfg | |
| 编辑/etc/ssh/sshd_config 文件,增加一行: | |
| AddressFamily inet |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import java.util.Stack; | |
| /** | |
| * 递归求解汉诺塔 | |
| */ | |
| public class HanoiTower { | |
| // 三个塔 a、b、c | |
| Stack<Integer> a,b,c; | |
| public static void main(String[] args) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| String dataFile = "data/NWP_NMC_T639R/Z_NAFP_C_BABJ_20161108000000_P_CNPC-T639-GMFS-HNEHE-00000.grib2"; | |
| try { | |
| // open netcdf/grib/grib2 file from argument | |
| NetcdfDataset gid = NetcdfDataset.openDataset(dataFile); | |
| // get all grid tables in the file | |
| List<Variable> variables = gid.getReferencedFile().getVariables(); | |
| for (int i = 0; i < variables.size(); i++) { | |
| Variable var = variables.get(i); | |
| if ((!var.isMetadata()) && (!var.getRanges().isEmpty())) { | |
| System.out.format("%s, %s: %s %s\n", var.getName(), var.getDataType().toString(),var.getRanges().toString(),var.getUnitsString()); |
分布式ping: http://ping.pe/
移动光猫:CMCCAdmin/aDm8H%MdA 改为桥接模式:https://www.sciencesoft.cn/china-mobile-routing-to-bridge-mode/
rpm --import https://www.elrepo.org/RPM-GPG-KEY-elrepo.org
rpm -Uvh https://www.elrepo.org/elrepo-release-7.0-4.el7.elrepo.noarch.rpm
yum --disablerepo="*" --enablerepo="elrepo-kernel" list available
yum --enablerepo=elrepo-kernel install -y kernel-ml
# 若出错,则运行以下命令
#grub2-mkconfig -o /boot/grub2/grub-efi.cfg
awk -F\' '$1=="menuentry " {print i++ " : " $2}' /etc/grub2.cfg
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ## Cannot git-clone from github | |
| ```bash | |
| git clone https://github.com/kaichao/app-mwa.git | |
| Cloning into 'app-mwa'... | |
| fatal: unable to access 'https://github.com/kaichao/app-mwa.git/': GnuTLS recv error (-110): The TLS connection was non-properly terminated. | |
| ``` |
set $req_header "";
set $resp_header "";
header_filter_by_lua_block{
local h = ngx.req.get_headers();
for k, v in pairs(h) do
ngx.var.req_header = ngx.var.req_header .. k.."="..v.." ";
- A networked server with Docker installed (can be any Linux distribution)
- A target offline server running Rocky Linux 9.4
- Both servers have the same architecture (e.g., x86_64)
The container image (rockylinux/rockylinux:9.4) provides an environment identical to the target offline server. This ensures all downloaded RPM packages are compatible, regardless of the networked server's host operating system.