Podcast #128: We chat with Kent C Dodds about why he loves React and discuss what life was like in the dark days before Git. Listen now.

Questions tagged [ascii-art]

ASCII Art is a graphic design technique that uses the 93 printable/space characters of the 128-character ASCII set to create images.

Filter by
Sorted by
Tagged with
64
votes
1answer
2k views

Printing binary trees

After writing this answer, I was inspired to try to design a more elegant solution to the problem of printing binary trees. And what better tool with which to seek elegance than Clojure? Overall ...
51
votes
6answers
13k views

ASCII text-based RPG game in C++

I started to make a C++ RPG game just for fun. It does have quests but it isn't just one long adventure that lasts like 30 minutes. I would like to know what I did well on and things on which I can do ...
41
votes
1answer
3k views

The right way to hang a man

Problem: I have seen a few questions around hangman. Usually this is done in a very hackish way, which usually can not be generalized any further. My thought or question is about the creation of the ...
23
votes
8answers
3k views

Writing nested for loops to produce certain output

My task: Write nested for loops to produce the following output with each line 48 characters wide: ...
21
votes
7answers
4k views

Print 10 × 10 square of X and O characters, split diagonally

I'm going through a beginners exercise for writing a small program in Java. My task is to print out (i.e. find an algorithm) the following output: ...
18
votes
2answers
4k views

Retro Rocket ASCII Art

Inspired by Nested for-loop ASCII art, I looked at building a more complicated ASCII art than just the normal 'diamond' and 'triangle' variations that crop up occasionally here. The challenge: ...
16
votes
1answer
3k views

Pretty printing of the numpy ndarrays

Following this idea for pretty printing of numpy ndarrays, I have developed a very primitive prototype: ...
16
votes
0answers
186 views

Rubik's cube mode for emacs

Following is a dumb implementation of Rubik's cube for Emacs. I am not well versed in writing (e)lisp, so I ask for a review and corrections. ...
14
votes
2answers
1k views

Python ASCII-Art Table

As a part of a console utilities module, I created a function that takes a table in the form of an array of arrays, and generates an ASCII table with the given contents. I've also added the options ...
13
votes
4answers
26k views

Printing star greater symbol in Java

I need to print this in Java, but I feel that my code is too big: * ** *** **** *** ** * ...
13
votes
2answers
7k views

Python ASCII-Art Text Generator

...
12
votes
4answers
383 views

Draw random 1's and 0's

I was wondering if anyone would be so kind as to look at this code I've written for practice. Tell me what am I doing wrong, where can I optimize, anything. What this code does is (in terminal) draw ...
12
votes
1answer
1k views

Printing large numbers, or not large but LARGE

I just started learning Java about a month ago. I'm wondering, what would an experienced developer do differently in the code below? As I learn to code, what direction should I be pushing myself? I ...
11
votes
7answers
3k views

Java diamond with numbers

I have an assignment to code a method that will print values in a diamond pattern. For example, if the method is called like printNumberDiamond(2), then the results ...
11
votes
5answers
6k views

ASCII generator

Today I stumbled upon CodinGame, a site with programming challenges. I'll describe one of them. ASCII art allows you to represent forms by using characters. To be precise, in our case, these forms ...
11
votes
1answer
528 views

The ugly Christmas tree, Haskell style

Inspired by a few inverse tree ascii art F# questions, I wanted to give it a shot in Haskell. As seen in the linked questions, the resulting program reads an Int ...
11
votes
1answer
688 views

ASCII flow chart drawer

After some free ASCII flowchart drawer started charging money, I decided to write my own. Salient features are that you can draw a box (mouse down, mouse move, mouse up), then ctrlB will draw a box. ...
10
votes
4answers
779 views

Console-based table structure: Revisited

This is a follow-up from my previous post, which can be found here. A readme for more detailed information can be found here. It is a library to create console based tables where you can insert, ...
10
votes
5answers
437 views

Circles of numbers

I have a function: ...
10
votes
4answers
3k views

ASCII art generator in C

I have written an ASCII art generator library. I was practicing data abstraction and code abstraction and I wanted to know if there is something that can be improved. File tree: ...
10
votes
1answer
142 views

Printing patterns in Haskell

Write a function Int -> Char -> Char -> [String] that will create the appropriate pattern. For example: ...
9
votes
5answers
5k views

Python odd number diamond

I worked up a quick diamond program that takes only odd numbers while returning an error with even numbers or 0. The code looks rather ugly to me, especially with the recurring ...
9
votes
1answer
1k views

Generate an Hour Glass pattern

Here is my code for making an Hour Glass pattern with odd or even input using Python. I think I could make it simpler. Here's the output example: And then, here is my code: ...
9
votes
1answer
79 views

ASCII Mandelbrot Set “image” producer

As an exercise, I decided to try implementing a Mandelbrot Set viewer that produces ASCII images. Small Example: ...
8
votes
3answers
2k views

Printing the number in large size

Problem Description Receive a 5 digit number and print out in a large size. Sample input 32145 Sample output ...
8
votes
2answers
3k views

Printing letters in order like a pyramid

There is this hackerrank question, where we need a rhombus of letters. As to my opinion it can be viewed as some fractal, or similar logic. Well I solved the question, but I am obviously disappointed ...
8
votes
3answers
13k views

Printing an hourglass pattern

In a recent interview I have been asked to write a program to generate the following output: ...
8
votes
2answers
240 views

Graphical editor programming challenge

I have posted here my working and accepted solution to the graphical editor programming challenge (detailed here) for your review. The program recognizes the following image editing commands: ...
8
votes
3answers
94 views

Drawing a table for data from file

I wrote a function for drawing a table for data that comes from file: ...
8
votes
2answers
385 views

Sierpinski triangle from Pascal triangle

I tried to draw a Sierpinski triangle by shading the even number entries of the Pascal triangle. Could you please suggest improvements? ...
8
votes
1answer
887 views

A small Java library for neat printing of binary trees to text console

Given a binary tree (not necessarily a binary search tree), this small Java library implements an algorithm that can neatly print binary trees to text console. Code BinaryTreeNode.java ...
7
votes
2answers
1k views

Homework to display a square and calculate tips

Here's a simple school assignment I did: Problem 1: Write a program that asks the user for a positive integer no greater than 15. The program should then display a square on the screen using ...
7
votes
3answers
1k views

Shrinking and expanding square

I'm a computer science student who's just starting out with algorithms and their implementation. I wrote this code for a dynamically morphing square. I was wondering if I could get a review on it. I ...
7
votes
3answers
3k views

Print a chessboard

I'm working through Eloquent Javascript and just did the examples in chapter 2. One is to create a chess board grid of arbitrary size. My code works, but the if/else if statements I used feel clunky. ...
7
votes
3answers
528 views

Displaying “C++” in ASCII art with user inputting an integer

I have a school assignment and would love it if you can criticize or give a couple of pointers/advice about my piece of code (don't give me the answer, breaks the point of the exercise). Here's my ...
7
votes
1answer
196 views

A Rusty implementation of CowSay

I'm making my first foray into Rust. I wanted to copy a fun and non utilitarian tool so I chose CowSay. It's not feature complete (CowSay has a lot of options) but it's a start. My primary reasons ...
7
votes
2answers
108 views

Color ASCII drawing class

I am working on a pseudo graphical interface for a Chess engine I wrote. I want to draw a colored Chess board with ASCII pieces. To abstract the pure ...
7
votes
1answer
182 views

Drawing a snowman in ASCII art

I am learning Go and as an exercise I did this challenge from Code Golf (without the golfing), where an ASCII art snowman is drawn from a combination of body parts, based on an 8-digit code taken as ...
7
votes
1answer
151 views

Code that prints ASCII bowties to screen given inputs

The goal of this program is to take an input from Stdin and output some ASCII bowties to Stdout. The first integer in the input represents the number of test cases. Each test case contains 2 ints and ...
7
votes
1answer
112 views

World's worst Christmas tree

Inspired by this question, I decided to grow my own fractal tree. The problem is: given an integer \$n\$, \$0 \leq n \leq 5\$, print the \$n\$th iteration of the fractal tree. The tree is probably ...
7
votes
1answer
599 views

Pretty print a tree

When you're working with trees one of the most useful methods to implement is a clear way to print them, the following is my solution to print a tree in Java: ...
7
votes
1answer
109 views

CS50 pset-1 itsa Mario - make a half-pyramid using parameters from user input

I'm taking Harvard's introduction to computer science (CS50) course online, and I've written a program that satisfies a coding challenge but I don't understand what I did or how I can improve it. I'm ...
6
votes
5answers
1k views

Show a diamond shape with numbers

After seeing this post on StackOverflow, I thought I'd try it out. What I have now is a diamond shape with numbers like this: ...
6
votes
2answers
378 views

ASCII art minesweeper clone

I wanted to code a small ASCII art minesweeper clone, to see what it looked like and how much code it needed. The result is not so bad, under 80 new lines of code in total. It looks kinda readable to ...
6
votes
3answers
16k views

Making a rectangular-shaped pattern

I'd like someone to suggest a better way to create this pattern in Java which I'm sure is possible: ...
6
votes
1answer
1k views

An ASCII histogram of a die rolled n times

A die is rolled n times. Each time, a random value has been inserted into a vector. This vector then is used to generate a sorted map (wrongly called hashmap in the code) that is later used to create ...
6
votes
2answers
7k views

Beginner Python Dungeon Crawler RPG

I made a game in python which plays a bit like old terminal based RPGs, though a lot more basic. I had originally intended to implement a weapons and armour system and thus remnants of this can still ...
6
votes
2answers
1k views

Triangle Tessellation Project

I have this Python project to draw tessellated triangles on the screen. It takes the height to form the size of the triangle, cols to specify how many triangles on a line, and rows which is how many ...
6
votes
3answers
3k views

Beginning of simple rogue-like RPG (in console) in C++

I've started to learn programming recently and it's my first more or less "big" project. But coding this project for me is quite hard. I spent a lot of time to understand what I've done and my coding ...
6
votes
3answers
953 views

Pretty-printed tables in Haskell

Purpose A clean, reusable module to generate pretty tables (much like those in SQL-clients), like so: ...