title: Why this uint16_t variable declaration doesn't work?
body: <p>I have to send a package from a udp client to udp server (i made) but the problem is that this declaration doesn't work</p>
  
  <pre><code>#define RRQ 1
  .
  .
  .
  
  uint16_t op = htons(RRQ);
  </code></pre>
  
  <p>i tryed also</p>
  
  <pre><code>uint16_t op = htons(1);
  </code></pre>
  
  <p>and </p>
  
  <pre><code>int k = 1;
  uint16_t op = htons(k);
  </code></pre>
  
  <p>but this doesn't put 1 in op but 256</p>
  
  <p>I tryed to send this package to the server, i receive the package and i get the same result server side (i find op == 256 and not op == 1 like it should)
  Thanks for the reading!</p>