any ideas in hangman

#include<iostream.h>
#include<stdlib.h>
#include<conio.h>
#include<string.h>
int main()
{
int x,y,z,a,s,b,c,d,e,f;
char v[20];
randomize();
clrscr();
char word[10][111]={"hi","bye","adf","tr","computer","program","school","game","play","pen"};
x=random(10);
y=strlen(word[x]);
strcpy(v,word[x]);
cout<<"number of letters in the given word is "<< y;
if(y>=3&&y<=6)
{
z=random(y);g
cout<<" one of the word is "<<word[x][z]<<" in position "<<z;
}
else if(y>6)
{
z=random(3);
a=y-3;
s=random(a)+3;
cout<<" "<<word[x][z]<<word[x][s]<<z<<s;
}
return 0;
}







i don't know how to check for the letter entered by the user is present or not i'm just a beginner so don't mistake me and please correct me
Last edited on
First off, please use code tags([.code] and [./code], without the dots).

Nextly, what do you want to know? If you want to get input from the user, use cin.
Topic archived. No new replies allowed.