title: Got three "Variable not in scope" errors in my Haskell code while doing module expressions for guards
body: <p>I have the following Haskell code with guards which are intended to print the following Strings when I entered a number for my function, meaning when it is divided by either 2, 3, or 5 it was intended to print a string containing the number in Spanish, otherwise printing &quot;Nada&quot;.</p>
  <pre><code>compositeNumber::Integer -&gt; String
  compositeNumber x 
      |(x % 2 == 0) = &quot;Dos&quot;
      |(x % 3 == 0) = &quot;Tres&quot;
      |(x % 5 == 0) = &quot;Cinco&quot;
      |otherwise = &quot;Nada&quot;
      
  main = print$ compositeNumber 4;
  </code></pre>
  <p>However, when I went to run my code, I got this error.</p>
  <pre><code>main.hs:3:9: error:
      Variable not in scope: (%) :: Integer -&gt; Bool -&gt; Bool
    |
  3 |     |(x % 2 == 0) = &quot;Dos&quot;
    |         ^
  
  main.hs:4:9: error:
      Variable not in scope: (%) :: Integer -&gt; Bool -&gt; Bool
    |
  4 |     |(x % 3 == 0) = &quot;Tres&quot;
    |         ^
  
  main.hs:5:9: error:
      Variable not in scope: (%) :: Integer -&gt; Bool -&gt; Bool
    |
  5 |     |(x % 5 == 0) = &quot;Cinco&quot;
    |         ^
  </code></pre>
  <p>I am still new to Haskell and I am currently learning it, and there are probably some things in the language which are unfamiliar to me. I would really appreciate it if you would help me find out how to fix this error!</p>