Last call to make your voice heard! Our 2022 Developer Survey closes in less than a week. Take survey.

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
5 votes
1 answer
202 views

Formatting a table using unicode symbols in python

The goal of the project is to take in input for a data, perhaps in the future as a csv, then print it out using UNICODE box-drawing characters. The main function ...
user avatar
  • 151
3 votes
2 answers
65 views

Alphabet Rangoli

I have written alphabet rangoli code in python and would like to get it reviewed. The goal is to print concentric diamond shapes made of letters, with "a" at the center, "b" ...
user avatar
2 votes
1 answer
54 views

c++ CLI Ascii image renderer

I am wondering if this is written well or not, I am just a beginner and would like some feedback what should I improve on. Thanks. ...
user avatar
0 votes
1 answer
74 views

Outputting a graphic using functions

How would you make this piece of code more simple/efficient? The problem should not be solved with one print statement, rather with functions Could you also give me any advice how I can come to your ...
user avatar
1 vote
2 answers
189 views

Create an ASCII table from CSV

The following code convert csv to ascii table. ...
user avatar
4 votes
0 answers
41 views

Diagonal square spiral pattern in Vyxal

I wrote this code as a reference implementation for this challenge. How can I make it more readable and/or efficient? The goal is to take an integer and create patterns like the following: ...
user avatar
4 votes
4 answers
607 views

Output a pyramid of numbers

I have this problem where I've to print a number pyramid by taking input from the user. 1 2 3 2 3 4 5 4 3 4 5 6 7 6 5 4 5 6 7 8 9 8 7 6 5 I've ...
user avatar
7 votes
3 answers
390 views

Draw a 2d graph using slashes

Given a list of integers a 2D graph has to be plotted taking 1st, 3rd, 5th, ... numbers as upward slope and 2nd, 4th, ... numbers as downward slope. I have used a Python list to do it. Is there any ...
user avatar
10 votes
1 answer
859 views

Printing a diamond shape in ASCII

...
user avatar
  • 123
1 vote
2 answers
49 views

Colour message prettifier in Bash

Features: messages formatted with clear borders errors sent to stderr colour handling colours can be included in other strings echoed to the screen without having ...
user avatar
  • 229
4 votes
1 answer
192 views

More efficient way to create an ASCII maze using box characters

I've written a C# program to generate a random maze, and then draw that maze in the Console mode using box-drawing characters, e.g. ─ │ ┌ ┐ ┬ ┼ etc. It works fine, as below, but I'm not convinced that ...
user avatar
  • 191
3 votes
3 answers
160 views

Printing dynamic ascii-art shapes based on user input

In the following code I used a while True: loop and implemented break, because I couldn't figure out a cleaner solution than an ...
user avatar
  • 115
5 votes
3 answers
695 views

Printing pyramids in C (CS50)

I'm taking the CS50 course, and we're asked to create a program which takes an input (the total height of the pyramid) and outputs a pyramid of that height. i.e Here’s how the program might work if ...
user avatar
  • 65
5 votes
2 answers
363 views

ASCII Random Walk Algorithm

I would like some advice on improving/optimizing a small program I wrote. What it does is run a random walk on a torus manifold with 8 colors that loop around. ...
user avatar
6 votes
2 answers
1k views

Recreate Mario's half-pyramids using hashes (#) from CS50

I currently working on CS50. There is a problem where we need to recreate half-pyramids using hashes (#). The hashes are to substitute blocks like in Mario. This is also the first time I'm using ...
user avatar
7 votes
0 answers
63 views

A program that calculates how dense each character appears when printed

I wanted to know how "dark" each character is when printed. I thought that this may be useful when doing ASCII-art to help with shading. I decided to write a program to objectively measure ...
user avatar
3 votes
1 answer
2k views

Tic Tac Toe with ASCII art

I have written a simple Tic Tac Toe game using some ASCII art. Is there anything I can do to improve upon the logic and structure of the program? ...
user avatar
8 votes
1 answer
906 views

ASCII-Art Generator

Introduction For the purpose of learning how to work with pictures in Java, I created an ASCII-Art Generator. The program can do two things: Convert pictures into ASCII-Art Convert text into ASCII-...
user avatar
1 vote
1 answer
71 views

Using Data.Array to solve Sierpinski in Haskell

Here is an earlier attempt to solve the original problem: Solving Sierpinski Triangle in Haskell I was never satisfied with my solution and found it was awkward and twisty. Here is another attempt to ...
user avatar
  • 317
5 votes
1 answer
210 views

Pythonic way to draw ascii christmas tree?

I hacked a way to print a christmas tree, to use it in the usual seasons greetings email, you know the drill. Next Step is to integrate a multi lines of text in the border left side of the tree. For ...
user avatar
1 vote
1 answer
302 views

Tower of Hanoi, ASCII animation with ANSI escape codes

A few days ago I saw a nice video on YouTube with prof Thorsten Altenkirch about recursion and the Tower of Hanoi puzzle. Today I tried to reproduce the code from the video and came to this: ...
user avatar
  • 1,451
4 votes
2 answers
129 views

Draw an outline of an upward-pointing triangle

I am beginner in C++ and I was given this assignment by my teacher. The assignment is to print the following shape: ...
user avatar
5 votes
3 answers
438 views

To print asterisks based on inputs

I have to print the number of stars that increases on each line from the minimum number until it reaches the maximum number, and then decreases until it goes back to the minimum number. After printing ...
user avatar
2 votes
0 answers
1k views

Program to draw ASCII art based on commands

I want to know how to improve the design of Canvas drawing implementation. Canvas Drawing This solution is to implement a console-based canvas drawing application. Problem Statement Description ...
user avatar
5 votes
2 answers
1k views

Printing a multiplication table in C [closed]

I'm a complete beginner, but I'd like to learn how to program. I really started 2 weeks ago. So I tried the common exercise, aka the multiplication table, but I tried to add little things I learnt ...
user avatar
4 votes
1 answer
91 views

Print a Connect 4 grid based on some rules for each cell

In a game of Connect4: we start with an empty grid two players place pieces X and O on the grid the first player to achieve 4 pieces in a line wins! this is a text based console game Here is the ...
user avatar
  • 143
4 votes
0 answers
70 views

Formatting CSV as a table using BDD

This is the problem: Write a function to create a table from CSV data. The input to the function is a list of strings. Each string is formatted as a CSV record. Here’s an example for a ...
user avatar
  • 41
3 votes
0 answers
355 views

ASCII-Box PowerShell menu

I've written a pair of functions that can be added to a module or script that will allow the developer to specify a list of options and let the user select with the up/down arrow and return any ...
user avatar
  • 219
9 votes
1 answer
138 views

ASCII Mandelbrot Set "image" producer

As an exercise, I decided to try implementing a Mandelbrot Set viewer that produces ASCII images. Small Example: ...
user avatar
1 vote
4 answers
485 views

Program that prints an ASCII pyramid

I have written the following program in C# to display an ASCII pyramid. ...
user avatar
2 votes
2 answers
187 views

Program that prints star pattern

I have a program that prints the star pattern. Starr Pattern is: ...
user avatar
7 votes
2 answers
143 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 ...
user avatar
1 vote
1 answer
301 views

Word count graph

I created a program in python that reads a file and outputs a frequency graph of the words it contains. Any feedback or tips would be appreciated. ...
user avatar
3 votes
1 answer
580 views

Program which accepts grades and prints grade distribution

I'm doing the MOOC Java course (CTRL+F "distribution"): The input of the program is a set of exam scores of a course. Each score is an integer. When -1 is entered, the program stops asking for ...
user avatar
  • 73
0 votes
2 answers
382 views

Print diamond shape in Java

I'm printing a diamond shape in Java. It's working fine, but is there a way to re-write this code to make it faster? ...
user avatar
7 votes
1 answer
419 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 ...
user avatar
  • 1,684
2 votes
3 answers
264 views

Display command-line Hangman

This code is part of my Hangman game. One of my minor issues is how to properly print out the hangman. Could you please give me hints on how to make the code less hardcoded? This code is so redundant,...
user avatar
  • 2,392
2 votes
1 answer
74 views

Create a histogram of the lengths of words

I am reading through K&R C 2nd Edition, and I am on exercise 1-13. The exercise is to write a program to print a histogram of the lengths of words in its input. I wrote a program that successfully ...
user avatar
9 votes
1 answer
2k 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: ...
user avatar
  • 91
4 votes
2 answers
241 views

Hangman v2 written in C

This is a follow up to my previous Code Review, and I have incorporated feedback I received in this revision of the code, along with some other improvements. I would appreciate your feedback on this ...
user avatar
  • 513
1 vote
2 answers
451 views

ASCII Mandelbrot

First of all, let me answer the question that a lot of you may have: The Mandelbrot set is the set of values of c in the complex plane for which the orbit of 0 under iteration of the quadratic map ...
user avatar
6 votes
1 answer
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 ...
user avatar
5 votes
2 answers
7k views

Printing concentric squares of numbers

I wrote a code which prints the following pattern : ...
user avatar
17 votes
1 answer
5k views

Pretty printing of the numpy ndarrays

Following this idea for pretty printing of numpy ndarrays, I have developed a very primitive prototype: ...
user avatar
  • 321
3 votes
0 answers
303 views

K&R Exercise 1-13. Printing histogram of word lengths (vertical variant)

I'm going through the K&R book (2nd edition, ANSI C ver.) and want to get the most from it. How does the following solution look to you? Note that, for the sake of exercise, I don't want to use ...
user avatar
  • 341
3 votes
2 answers
508 views

K&R Exercise 1-13. Printing histogram of word lengths (horizontal variant)

I'm going through the K&R book (2nd edition, ANSI C ver.) and want to get the most from it. How does the following solution look to you? Note that, for the sake of exercise, I don't want to use ...
user avatar
  • 341
1 vote
1 answer
585 views

Drawing concentric circles to console

This prints out a triple layer circle with 12 points per circle and finds the points across a grid. I had a really hard time with this and I'm planning to implement a lot more code but I don't want ...
user avatar
3 votes
1 answer
1k views

Printing right triangles recursively in Haskell

I've implemented a simple program to print out 4 right triangles oriented in different ways to learn Haskell. I'm sure there are more efficient ways of doing what I have done, and I just want some ...
user avatar
3 votes
2 answers
83 views

Initializing a tile-like map such that the edges are marked with an 'X'

I've been messing around with arrays as I'm learning them currently in my book and they gave the idea of a chess board using for loops alongside multidimensional arrays to give them individual values ...
user avatar
  • 117
8 votes
1 answer
2k 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: ...
user avatar
  • 189