#include <iostream>
#include <string>
using namespace std;

long getBarcode(long code);
//Gets the Barcode from the individual.
long verifyCode();
//verifys the code and makes the appropriate conversions.
void displayCode(long& code);
//Dislpays the barcode given by the individual.

int main()
{
    long code;


    displayCode(code);
    return 0;
}
long getBarcode(long code)
//Gets the Barcode from the individual.
{
    cout << "Enter the five digit barcode:" << endl;
    cin >> code;

    while(code > 99999 || code < 0)
    {
        cout << "Re-enter the barcode" << endl;
        cin >> code;
    }

    return code;
}
long verifyCode()
//verifys the code and makes the appropriate conversions.
{


    return 0.0;
} 
void displayCode(long& code)
//Dislpays the barcode given by the individual.
{
    int a, b, c, d, e, rm, rm2, rm3, rm4;

    code = getBarcode(code);
a=code/10000;
rm=code%10000;
b=rm/1000;
rm2=rm%1000;
c=rm2/100;
rm3=rm2%100;
d=rm3/10;
rm4=rm3%10;
e=rm4;


    /*if(a==0)
    {
        a='||::';

    }

    if(a=1)
    {
        a=':::||';
    }
    if(a=2)
    {
        a='::|:|';
    }
    if(a=3)
    {
        a='::||:';
    }
    if(a=4)
    {
        a=':|::|';
    }
    if(a=5)
    {
        a=':|:|:';
    }
    if(a=6)
    {
        a=':||::';
    }
    if(a=7)
    {
        a='|:::|';
    }
    if(a=8)
    {
        a='|::|:';
    }
    if(a=9)
    {
        a='|:|::;';
    }
*/

cout<<a<<endl;








cout << "|"<</*a<<*/"|"<<endl;
}

First: Please wrap your code in Code tags. The easy way is to press the Code button on the toolbar, then paste your code; or you can paste first, highlight your code and then press. The result:

  • Your parentheses and semi-colons don't interact to make smilies
  • Your indentation is maintained
  • There are line numbers which makes it easy to refer back to a particular issue
  • There is keyword coloring

All these are good things.

Second: What is your question? "Please help" isn't much use in understanding what help you need.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.