title: Create a Struct In Java Like C++
body: <p>i want to create an struct in java , like c++ :</p>
  
  <pre><code>struct MyStruct {
      int x;
  };
  #include &lt;iostream&gt;
  int main() {
      MyStruct Struct;
      Struct.x = 0;
      std::cout &lt;&lt; Struct.x;
      return 0;
  }
  </code></pre>
  
  <p>can anyone help me ?</p>