How to resolve the algorithm Rare numbers step by step in the EasyLang programming language

Published on 12 May 2024 09:40 PM

How to resolve the algorithm Rare numbers step by step in the EasyLang programming language

Table of Contents

Problem Statement

Rare   numbers are positive integers   n   where:

Show all output here, on this page.

Let's start with the solution:

Step by Step solution about How to resolve the algorithm Rare numbers step by step in the EasyLang programming language

Source code in the easylang programming language

fastfunc next n .
   while 1 = 1
      n += 1
      h = n
      nrev = 0
      while h > 0
         nrev = nrev * 10 + h mod 10
         h = h div 10
      .
      if sqrt (n + nrev) mod 1 = 0
         if n - nrev >= 1 and sqrt (n - nrev) mod 1 = 0
            return n
         .
      .
   .
.
for cnt to 5
   n = next n
   print n
.

  

You may also check:How to resolve the algorithm Bitmap/Flood fill step by step in the Lingo programming language
You may also check:How to resolve the algorithm 21 game step by step in the bash programming language
You may also check:How to resolve the algorithm Pernicious numbers step by step in the Modula-2 programming language
You may also check:How to resolve the algorithm Bitmap/Bézier curves/Cubic step by step in the Nim programming language
You may also check:How to resolve the algorithm Deepcopy step by step in the Wren programming language