0

So I need to print a title using \ __ ||

it will become something like this

  ______
 |_   _ \
   | |_) |
   |  __'.
  _| |__) |
 |_______/

how to print all, and i get error even though i use \ to print \

1
  • 2
    Show us your code and the actual error you're getting. Commented Mar 2, 2014 at 22:31

2 Answers 2

1

To print \ you need to put \\ in your string, because \ is an escape (e.g. \n for a new line).

Sign up to request clarification or add additional context in comments.

Comments

0

I'm able to print out your image with this code:

char* thing = "  ______\r\n |_   _ \\\r\n   | |_) |\r\n   |  __'.\r\n  _| |__) |\r\n |_______/";

int main( void )
{
    printf("%s",thing);
    return 0;
}

What you need is a string escaping tool, if you plan on escaping complex images. I used one at http://www.freeformatter.com/java-dotnet-escape.html#ad-output

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.