V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX  ›  GeekGao  ›  全部回复第 1 页 / 共 101 页
回复总数  2014
1  2  3  4  5  6  7  8  9  10 ... 101  
1 天前
回复了 kekeones 创建的主题 程序员 请教下 windows 驱动里的加解密
当然适合。很多透明加密程序的驱动实现都是用了 AES
1 天前
回复了 luxu 创建的主题 Kubernetes 自建 k8s, 外部如果访问对应的 TCP 服务?
Ingress 就行了啊
个人最近感觉:
咖啡机
外卖
都涨价了
线上产品的集群里曾经有几十个核,但是最大使用率估计不超过 10% 我们是用华为云的 x86 实例。除非感受到性能瓶颈了,不然还是不要提前折腾了
全局状态用 Jotai 库管理即可
3 天前
回复了 biuyixia 创建的主题 程序员 QQ 邮箱不要 FACE 啊
tx 邮箱只有几个码农维护… 有问题也属于正常了,沟通能解决最好(企业邮那边服务还凑合),不能的话就不要用了。
@liuidetmks 中国不允许有小利益集团存在,例如什么工会、互助会、行会 (手动猫头
这种站,只适合骗骗国内新人。在国际上属于垃圾站,权重不会高的。
4 天前
回复了 xzour 创建的主题 程序员 内部系统如何优雅的管理各种第三方接口
还是多年前的 SOA 治理问题
4 天前
回复了 wangpugod2003 创建的主题 程序员 讨论一道面试题啊(take home task)
意思是说这思路不行???

import java.io.*;
import java.util.PriorityQueue;

public class ExternalSorter {
public static void main(String[] args) throws IOException {
String inputFile = "bigfile.txt"; // 输入文件路径
String tempDirectory = "temp"; // 临时文件目录
int maxMemory = 1024*1024*1024; // 假设最大内存使用量限制为 1GB

try (BufferedReader reader = new BufferedReader(new FileReader(inputFile))) {
String line;
int fileCounter = 0;
while ((line = reader.readLine()) != null) {
// 使用 PriorityQueue 在内存中对行进行排序
PriorityQueue<String> sortedLines = new PriorityQueue<>();
sortedLines.add(line);

// 继续读取行,直到内存使用达到限制
int memoryUsage = line.length();
while (memoryUsage <= maxMemory && (line = reader.readLine()) != null) {
sortedLines.add(line);
memoryUsage += line.length();
}

// 将排序后的行写入临时文件
File tempFile = new File(tempDirectory, "tempfile" + fileCounter + ".txt");
try (BufferedWriter writer = new BufferedWriter(new FileWriter(tempFile))) {
while (!sortedLines.isEmpty()) {
writer.write(sortedLines.poll());
writer.newLine();
}
}

fileCounter++;
}
}

// 合并临时文件
mergeTemporaryFiles(tempDirectory);

// 清理临时文件
cleanUpTemporaryFiles(tempDirectory);
}

private static void mergeTemporaryFiles(String tempDirectory) throws IOException {
File[] tempFiles = new File(tempDirectory).listFiles();
PriorityQueue<BufferedReader> readers = new PriorityQueue<>((br1, br2) -> {
try {
String line1 = br1.readLine();
String line2 = br2.readLine();
return line1.compareTo(line2);
} catch (IOException e) {
throw new RuntimeException(e);
}
});

for (File tempFile : tempFiles) {
BufferedReader reader = new BufferedReader(new FileReader(tempFile));
readers.add(reader);
}

String outputFile = "output.txt"; // 输出文件路径
try (BufferedWriter writer = new BufferedWriter(new FileWriter(outputFile))) {
while (!readers.isEmpty()) {
BufferedReader reader = readers.poll();
String line = reader.readLine();
if (line != null) {
writer.write(line);
writer.newLine();
readers.add(reader);
} else {
reader.close();
}
}
}
}

private static void cleanUpTemporaryFiles(String tempDirectory) {
File[] tempFiles = new File(tempDirectory).listFiles();
for (File tempFile : tempFiles) {
tempFile.delete();
}
}
}
4 天前
回复了 wangpugod2003 创建的主题 程序员 讨论一道面试题啊(take home task)
外部排序:

1.将文件分割成多个小块,每个小块可以在内存中排序。
2. 对每个小块进行排序,并将排序后的小块写入临时文件。
3. 合并所有排序后的小块,得到一个大的排序数组。
4.从排序后的数组中选择最大的 n 个值的 ID 。
" 国内的公有云基本没有可以一直白嫖的每月免费额度,阿里云,腾讯云,华为云都没有 "

怎么没有啊,前提: 你是个科技企业,有长期云上消费的计划,云商客户经理们愿意申请一些测试/免费额度给你的。
你是个纯纯抠门散户,抱着白 piao 的态度来的… 就甭指望平台做慈善了。
苍白的现实:世上不缺 idea 、市场不缺卖方、中国不缺卖力干活的人…
问题是:缺什么?
答:缺销售渠道!
7 天前
回复了 l2d 创建的主题 酷工作 [阿里安全] 招聘安全运营工程师
杭州群众都知道,wb 纯白色工牌不如狗,哈哈哈哈哈
8 天前
回复了 lstz 创建的主题 程序员 不解,为什么程序员做产品一定要出海?
其他的关于行政审批、工商要求之类的,只能是说在中国大陆想 100%合法合规的低成本起步,相比较于境外发达的经济体而言起步门槛高一些(当然,对比中国大陆自己的政策,行政方面的门槛比 2007 年高一些,那会儿没这么多审批项,gov 对互联网的监管还没有如今的体系)。

防杠: 什么“你规模小不会找你麻烦” “你可以找代办啊” 这种不是 100%合规且具有行政处罚风险的 idea 就不要提了。
8 天前
回复了 lstz 创建的主题 程序员 不解,为什么程序员做产品一定要出海?
主要还是汇率差诱人。 北美消费者一个月花 5 块美金买你的软件,相对于中国内地让大家掏 35 块钱消费软件要容易一些。
当然,有的人会说 “XXX 市场大啊,人口基数多啊“ ,以我的经验而言,印度市场就不太行( ROI 极低),所以出海赚钱和人口数量没必然关系。
1  2  3  4  5  6  7  8  9  10 ... 101  
关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   4162 人在线   最高记录 6543   ·     Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 50ms · UTC 05:26 · PVG 13:26 · LAX 22:26 · JFK 01:26
Developed with CodeLauncher
♥ Do have faith in what you're doing.