title: Print Class Variables in Swift - Expected Declaration Error
body: <p>do you know what's wrong?
  I just want to print a class' variable.
  I think the print have to be inside a method, but I don't know how exactly.</p>
  
  <pre><code>import UIKit
  
  
  class Class {
      var name: String
      init(name:String){
          self.name
  }
  
  class Subclass : Class {
      var level: Int
      init(name:String, level:Int){
          self.level
          super.init(name: name)
      }
  }
  
  var subclass1 = Subclass(name: "Hallo", level: 10)
  print(subclass1.level)            // &lt;-- here I get the error "Expected Declaration"
  </code></pre>
  
  <p><a href="http://i.stack.imgur.com/ij3iC.png" rel="nofollow">Screenshot of code</a></p>