本文介绍了如何从bash管道读取数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 29岁程序员,3月因学历无情被辞! 我刚刚开始编写程序...而我的第一个任务就是设置自己就是写一个会产生神秘的小程序 文字来源。一个神秘的词汇基本上是一个ceaser cypher但随机分配的字母而不是仅仅将向下移动一个值。那么..我在想,对于文本来说,BSD的财富游戏对于 gnixes来说是一个很好的来源。然而..我不是 确定如何将来自其他来源的数据读入C ++程序.. 我想做... b $ b $ fortune | crypticbyword 并让它输出神秘的字谜。如何从 bash管道读取数据? 帮助? joshuaI am just beginning to write programs... and my first task that I haveset myself is to write a little program that will generate crypticbywords from a source of text. A cryptic byword is basically a ceasercypher but with randomly assigned letters rather than just shifteddown by a value. So.. I am thinking that the BSD fortune game for thegnixes is a good source for the text to cypher. HOWEVER.. I am notsure how to read data in from another source into a C++ program..I would like to do ...$fortune | crypticbywordand have it output the cryptic byword. How does one read data from abash pipe?Help?joshua推荐答案 fortune | crypticbyword 并让它输出神秘的字谜。如何从 bash管道读取数据? 帮助? joshuafortune | crypticbywordand have it output the cryptic byword. How does one read data from abash pipe?Help?joshua " j。德尔" <做******* @ gmail.com>在消息中写道 news:23 ************************** @ posting.google.c om ..."j. del" <do*******@gmail.com> wrote in messagenews:23**************************@posting.google.c om...我刚刚开始编写程序......而我自己设定的第一项任务就是编写一个程序,它会从源代码中产生含义的含义。文本。一个神秘的词汇基本上是一个塞瑟尔的密码,但随机分配的字母而不是仅仅向下移动一个值。那么......我认为 gnixes的BSD财富游戏是文本加密的好来源。但是......我不确定如何将数据从其他来源读入C ++程序.. 我想做...I am just beginning to write programs... and my first task that I have set myself is to write a little program that will generate cryptic bywords from a source of text. A cryptic byword is basically a ceaser cypher but with randomly assigned letters rather than just shifted down by a value. So.. I am thinking that the BSD fortune game for the gnixes is a good source for the text to cypher. HOWEVER.. I am not sure how to read data in from another source into a C++ program.. I would like to do ...财富|神秘的词汇 并让它输出神秘的词汇。如何从 bash管道读取数据? joshuafortune | crypticbyword and have it output the cryptic byword. How does one read data from a bash pipe? Help? joshua 我从来没有听说过bash pipe,(或许多其他条款也是如此)。 难道我们过去常常在70年代吸烟吗? :-) 但我相信当你管道时数据进入一个应用程序,它只是在标准输入流中出现。查看如何使用std :: cin。我认为 就是答案。 -HowardI''ve never heard of a "bash pipe", (or many of those other terms, either).Isn''t that something we used to smoke back in the ''70s? :-)But I believe that when you "pipe" data into an application, it simplyappears in the standard input stream. Look up how to use std::cin. I thinkthat''s the answer.-Howard 这篇关于如何从bash管道读取数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云!
07-26 11:07