title: How to convert 32 bit integer to network byte order?
body: <p>How to convert the 32 bit integer to network byte order.</p>
  
  <p>What is the right way to do that?</p>
  
  <pre><code>[1024].pack("N")
  </code></pre>
  
  <p>OR</p>
  
  <pre><code>[1,0,2,4].pack("N")
  </code></pre>
  
  <p>Thanks</p>