title: Spacing between two strings in Java
body: <p>I'm taking this course online, and I can't really go back cause there are 23 lessons I've already finished and I don't remember which one of them told me about spacing something inside of a string</p>
  
  <p>So basically it is printing out</p>
  
  <pre><code>Joe Bloggs   37
  Sarah Smith   20
  </code></pre>
  
  <p>I want there to be a space between the name and the age of <code>person1</code> and <code>person2</code>.</p>
  
  <p>How would I go about doing that?</p>
  
  <p>I tried <code>\n</code> and <code>\t</code> but my compiler yells at me.
  And I'm still a beginner so I don't understand what the error message means.</p>
  
  <p>here's the code:</p>
  
  <pre><code>class Person {
  
      String name;
      int age;
  
  }
  
  
  public class Application {
  
      public static void main(String[] args) {
  
          Person person1 = new Person();
          person1.name = "Joe Bloggs";
          person1.age = 37;
  
          Person person2 = new Person();
          person2.name = "Sarah Smith";
          person2.age = 20;
  
          System.out.println(person1.name + person1.age);
          System.out.println(person2.name + person2.age);
  
      }
  
  }
  </code></pre>