title: Declaration syntax error in function
body: <p>Please help me fix this problem I typed the code at school too even there it showed declaration syntax error. -.- Cannot figure this out! . Its so frustrating when you have just begun with learning coding.</p>
  
  <p>void issue error: declaration syntax error
  void display error: illegal use of pointer</p>
  
  <p>Apologies if any folly in me found.</p>
  
  <pre><code>#include &lt;iostream.h&gt;
  #include &lt;conio.h&gt;
  #include &lt;stdio.h&gt;
  #include &lt;string.h&gt;
  
  
  class book
  {
  char bookname[20];
  char isbn[20];
  char author[20];
  char category[20];
  float price;
  int noc;
  
  public:
  
  void accept()
  {
  
  cout&lt;&lt;"Enter book name :- \n";
  gets(bookname);
  cout&lt;&lt;"Enter isbn no of the book:- \n";
  gets(isbn);
  cout&lt;&lt;"Enter authour name:- \n";
  gets(author);
  cout&lt;&lt;"Enter category of book:- \n";
  gets(category);
  cout&lt;&lt;"Enter price of the book :- \n";
  cin&gt;&gt;price;
  cout&lt;&lt;"Enter no of copies of book available in the library :- \n";
  cin&gt;&gt;noc;
  }
  
  void display()
  {
  puts(bookname)&lt;&lt;endl;
  puts(isbn)&lt;&lt;endl;
  puts(author)&lt;&lt;endl;
  puts(category)&lt;&lt;endl;
  cout&lt;&lt;price&lt;&lt;endl;
  cout&lt;&lt;noc&lt;&lt;endl;
  }
  
  }b[5];
  
  int main()
  {
  for(int i=0;i&lt;5;++i)
  {
  b[i].accept();
  }
  
  void issue()
  {
  int flag=0;
  char booksearch[20];
  cout&lt;&lt;"Enter name of book member wants to issue :- \n"
  gets(booksearch);
    for(i=0;i&lt;5;++i)
    {
        flag=strcmp(booksearch,b[i].bookname)
    }
  
  }
  
   if(flag==1)
   {
     b[i].display();
     b[i].issue();
   }
   getch();
   return 0;
   }
  </code></pre>