ASCII Art – Challenge | Coding Like A Grekz
Maybe your like
ASCII Art – Challenge
November 17, 2015 Leave a comment Go to commentsThis is the solution of the ASCII Art problem in the CodinGame page. https://www.codingame.com/games/puzzles
import java.util.*; import java.io.*; import java.math.*;
/** @author Juan Mendoza grekz.wordpress.com * ASCII art allows you to represent forms by using characters. To be precise, in our case, these forms are words. For example, the word “MANHATTAN” could be displayed as follows in ASCII art: * * # # # ### # # # ### ### # ### * ### # # # # # # # # # # # # # # * ### ### # # ### ### # # ### # # * # # # # # # # # # # # # # # # # * # # # # # # # # # # # # # # # # * * Your mission is to write a program that can display a line of text in ASCII art. **/ class Solution {
public static void main(String args[]) { Scanner in = new Scanner(System.in); int L = in.nextInt(); in.nextLine(); int H = in.nextInt(); in.nextLine(); String T = in.nextLine().toUpperCase(); String [][] chars= new String[27][H]; for (int i = 0; i < H; i++) { String ROW = in.nextLine(); for(int j = 0; j < 27; j++){ chars[j][i] = ROW.substring(j*L, (j+1) * L); } } for (int i = 0; i < H; i++) { for(char x : T.toCharArray() ){ x -= 65; if(x < 0 || x > 26) x = 26; System.out.print(chars[x][i]); } System.out.println(); } } }
Share this:
- X
Related
Categories: Beyond, CodinGame, Java, snippets Comments (0) Trackbacks (0) Leave a comment Trackback- No comments yet.
- No trackbacks yet.
Leave a comment Cancel reply
Unary encoded for 7-bit ASCII Simplify a fraction in Java RSS feedSuuuuuuuuuscrebaseee
Escribe tu mail para recibir notificaciones ;)
Email Address:
Sign me up!
Join 4 other subscribersTwittea acá!
Tweets by el_grekzLos posts más populares!
- npm ci task - ERR! string.prototype.trimend not accessible from es-abstract
- Good-to-great - Key points - The flywheel and the doom loop
- Good-to-great - Key points - Technology accelerators
- Good-to-great - Key points - A culture of discipline
Nuestras categorías son...
Algoritmo Arte Beyond Diseño Diversion Educación Golang idiomas Java JavaScript JSF leetcode Mini-tips Oracle plsql pregunta diaria Programación Python ruby Scala snippets SQL Tips Uncategorized WebEtiquetas más usadas
alemán alternativo Arte ascii ascii to char best time to buy and sell stock CEOs chiste Code Codigo codingame contains duplicate CSS duplicated elements easy excel column FacesContext fenómeno francés Frases en otros idiomas Genghis Khan git go Golang goldbach conjecture good-to-great google hamming distance hard HTML httpserver HttpServletRequest idiomas inglés italiano java java ascii javascript Java Server Faces jQuery js JSF keypoints kotlin leetcode Linux List medium Merge Lists Mitología griega MySQL nada Oracle oracle db oracle sql Pascal triangle performance pots programa java Python python3 query remo res ruby rómulo Scala siglo de oro simplehttpserver SMS solution SQL string string manipulation Valid Parentheses Top Blog at WordPress.com.- Comment
- Reblog
- Subscribe Subscribed
-
Coding like a Grekz | Uy turrun tun tun Sign me up - Already have a WordPress.com account? Log in now.
-
-
-
Coding like a Grekz | Uy turrun tun tun - Subscribe Subscribed
- Sign up
- Log in
- Copy shortlink
- Report this content
- View post in Reader
- Manage subscriptions
- Collapse this bar
-
Tag » Codingame Ascii Art Solution Python
-
CodinGame-Solutions/07-ascii-3 At Master - GitHub
-
CodinGame-Solutions/ At Master - ASCII Art - GitHub
-
CodinGame Python - E6 - ASCII Art - YouTube
-
[Codingame - Puzzle Facile] - 7. Ascii Art [Python3] - YouTube
-
Codingame Solution: ASCII Art
-
CodinGame Solo Puzzle - ASCII Art - Solved By Etienne THIERY
-
[Community Puzzle] Number Shifting - CodinGame Forum
-
ASCII Art Puzzle Discussion - CodinGame - Coding Game
-
Can Any Expert Help Me With The Solution Of This Puzzle On Codingame
-
Code Golf - From Text To Ascii Art From CodinGame Practice Puzzle
-
What Kind Of Experience Is It To Learn Programming While Playing ...
-
Aurélien Despons / CodinGame · GitLab
-
CodinGame - Puzzle ASCII Art Par LucasLethuillier - Page 1
-
Codingame - ASCII Art 思路- 代码先锋网