title: Error CS1001 (Identifier expected)
body: <p>I'm new to programming and am taking a C# class. I am getting compiler error CS1001 when I try to write this program. </p>
  
  <p>I read the Compiler Error description (link below), but I'm really not getting it. What am I doing wrong?</p>
  
  <p><a href="http://msdn.microsoft.com/en-us/library/b839hwk4.aspx" rel="nofollow">http://msdn.microsoft.com/en-us/library/b839hwk4.aspx</a></p>
  
  <p>Here is my source code:</p>
  
  <pre><code>using System;
  public class InputMethodDemoTwo
  {
     public static void Main()
     {
        int first, second;
        InputMethod(out first, out second); 
        Console.WriteLine("After InputMethod first is {0}", first);
        Console.WriteLine("and second is {0}", second);
     }
     public static void InputMethod(out first, out second) 
     // The error is citing the line above this note.
     {
        one = DataEntry("first"); 
        two = DataEntry("second");
     }
        public static void DataEntry(out int one, out int two)
        {
           string s1, s2;
           Console.Write("Enter first integer ");
           s1 = Console.ReadLine();
           Console.Write("Enter second integer ");
           s2 = Console.ReadLine();
           one = Convert.ToInt32(s1);
           two = Convert.ToInt32(s2);
        }
  }
  </code></pre>
  
  <p>According to the instructions, I'm supposed to have a method b (InputData) which pulls statements from method c (DataEntry)... Here are the instructions: </p>
  
  <blockquote>
    <p>The InputMethod()in the InputMethodDemo program in Figure 6-24 contains repetitive
    code that prompts the user and retrieves integer values. Rewrite the program so the
    InputMethod()calls another method to do the work. The rewritten InputMethod()
    will need to contain only two statements:</p>
    
    <p>one = DataEntry("first");</p>
    
    <p>two = DataEntry("second");</p>
    
    <p>Save the new program as InputMethodDemo2.cs." </p>
    
    <p>The InputMethodDemo they are referring to is the same program, except that it calls only one method (the InputMethod) instead of two.</p>
  </blockquote>
  
  <p>The text I referred to above is "Microsoft® Visual C#® 2008, An Introduction to Object-Oriented Programming, 3e, Joyce Farrell"</p>
  
  <p>Any advice/ help would be greatly appreciated. </p>