Posted on 2000-02-26
Last Modified: 2012-06-27
Hi, all experts

  Do any body know the ANSCII code for

border like MS WORD (ex. |========) for console program or dos enviroment. I am not really sure it is probably around 2 hundred something...  

Any body have an idea and want to challeng


Question by:lseng
  • 2

Expert Comment

ID: 2561530
#include <stdio.h>

void main(){
for(int i= 0; i < 70; i++){

Accepted Solution

roaknog earned 3 total points
ID: 2561602
// for a square
#include <stdio.h>

void main(){
      int c = 0, r = 0, letter = 0, rows = 20, collumns = 40;

      for(r = 0; r < rows+1; r++){
      for(c = 0; c < collumns+1; c++){
// conditions
            if((r == 0 || r == rows) && (c > 0 && c < collumns))letter = 205;//top and bottom
            if(r == 0 && c == 0) letter = 201;// top left
            if(r == 0 && c == collumns)letter = 187;// top right
            if(r == rows && c == 0) letter = 200;// bottom left
            if(r == rows && c == collumns)letter = 188;// botoom right
            if(r > 0 && r < rows && c > 0 && c < collumns)letter = 32;//center
            if((r > 0 && r < rows) && (c == 0 || c == collumns))letter = 186;//sides

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

IntroductionThis article is the second in a three part article series on the Visual Studio 2008 Debugger.  It provides tips in setting and using breakpoints. If not familiar with this debugger, you can find a basic introduction in the EE article loc…
This article shows you how to optimize memory allocations in C++ using placement new. Applicable especially to usecases dealing with creation of large number of objects. A brief on problem: Lets take example problem for simplicity: - I have a G…
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

914 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now