如何在控制台 screen/output 上显示多行内容,在本例中使用 java //notepad 在命令提示符下

how to display anything multi line as it is on console screen/output in this case on command prompt using java //notepad

http://www.text-image.com/convert/ascii.html

我用 Text-Image.com 制作了一条龙的 ASCII 字符图像,我想用我的 java 程序

在命令提示符中显示它

我知道如何创建批处理文件// 是他们开火的方式

https://youtu.be/ScQBQ0yYGfM

 String line = "Information \n " + 
               "More \n " + 
               "Even  stuff \n";

               System.out.println(line);

试过了,但是让每一行都与图像匹配是非常痛苦的

提前致谢:)

ASCII 格式的龙图像char/text 在命令提示符下

你可以试试这个方法:

private void printTxt(String image)
{
    /*
        image variable stores the path to the .txt file
        that contains the ASCII image.
    */
    try
    {
        BufferedReader br = new BufferedReader(new InputStreamReader(new FileInputStream(image)));

        String line;

        while((line = br.readLine()) != null)
        {
            System.out.println(line);

        }

        br.close();
    }catch(IOException e)
    {
        //handle the exception
    }
}

结果显示龙耶! [1]: http://i.stack.imgur.com/DoYVG.png

是用我自己的方法做的 像这样

   String line = "Information \n " + 
                 "More \n " + 
                 "Even  stuff \n";

                 System.out.println(line);

但是感谢 +THEvoid 的回答,我不知道如何实施我昨天才开始的解决方案;学习 java

我不知道如何将包含龙的 ASCII img 的 txt 文件的路径分配给图像变量