noob with a progblem in program
i am writing a program, te part i ahve fnished it below
Quote:
// Hex Code Finder
// Created by Daniel Strong
// Feel free to edit this and redistribute this. but you Must leave the above lines there! exactly how they are!
#include <iostream>
#include <string>
#include <stdlib.h>
#include <windows.h>
using namespace std;
int main()
{
string input;
bool black = "OOOOOO"
bool white = "FFFFFF"
cout << "Type in a Color to reveal its hexcode. Type All to view all colors indexed." << endl ;
cin >> input;
if(bool input = black)
{
cout << "The Hex Code for black is... #000000" << input << endl ;
Sleep(5000);
}
else if(bool input = white)
{
cout << "The Hex Code for white is... #FFFFFF" << input << endl ;
Sleep(5000);
}
cin.get();
return 0;
}
Problem #1. there is any error, i fixed it once, but i must of did osmething and it returned
Problem #2. isntead of dipsplaying the varibale it displays 1
guys please no one steal my idea of my program. This is my firts program and I dont want it to be stupid and useless because somoen else made it.