Data update
This commit is contained in:
parent
5150844a7d
commit
4bb20c9b71
7735 changed files with 38060 additions and 199180 deletions
|
|
@ -1,22 +0,0 @@
|
|||
$c = 0
|
||||
$k = 0
|
||||
While $c < 8
|
||||
$k += 1
|
||||
$n = $k
|
||||
While $n <> 1
|
||||
$s = StringSplit($n, "")
|
||||
$t = 0
|
||||
For $i = 1 To $s[0]
|
||||
$t += $s[$i] ^ 2
|
||||
Next
|
||||
$n = $t
|
||||
Switch $n
|
||||
Case 4,16,37,58,89,145,42,20
|
||||
ExitLoop
|
||||
EndSwitch
|
||||
WEnd
|
||||
If $n = 1 Then
|
||||
ConsoleWrite($k & " is Happy" & @CRLF)
|
||||
$c += 1
|
||||
EndIf
|
||||
WEnd
|
||||
|
|
@ -1,24 +0,0 @@
|
|||
$c = 0
|
||||
$k = 0
|
||||
While $c < 8
|
||||
$a = ObjCreate("System.Collections.ArrayList")
|
||||
$k += 1
|
||||
$n = $k
|
||||
While $n <> 1
|
||||
If $a.Contains($n) Then
|
||||
ExitLoop
|
||||
EndIf
|
||||
$a.add($n)
|
||||
$s = StringSplit($n, "")
|
||||
$t = 0
|
||||
For $i = 1 To $s[0]
|
||||
$t += $s[$i] ^ 2
|
||||
Next
|
||||
$n = $t
|
||||
WEnd
|
||||
If $n = 1 Then
|
||||
ConsoleWrite($k & " is Happy" & @CRLF)
|
||||
$c += 1
|
||||
EndIf
|
||||
$a.Clear
|
||||
WEnd
|
||||
Loading…
Add table
Add a link
Reference in a new issue