Submission details
Task:Lukujono
Sender:alli
Submission time:2025-10-29 18:46:22 +0200
Language:text
Status:READY
Result:44
Feedback
groupverdictscore
#1ACCEPTED44
Test results
testverdicttimescore
#1ACCEPTED0.00 s44details

Code

# Checking if it is one should be made more efficient, maybe by keeping track of it is one every time a change to V is made? only needs to be done on division
INCREASE U
REPEAT X TIMES ( # Sets Q to 1 if we should print anything after. if its zero, we dont do anything
    INCREASE V
	REPEAT O TIMES ( # Runs on second ( V > 1 ), sets Q = 1
		CLEAR O
		INCREASE Q
	)
	REPEAT U TIMES ( # Runs on first
		CLEAR Q
		INCREASE O
		CLEAR U
	)
)
PRINT X
CLEAR X
INCREASE E # Later should be replaced with 1000 or similar
INCREASE E
INCREASE E
INCREASE E
INCREASE E
INCREASE E
INCREASE E
INCREASE E
INCREASE E
INCREASE E
REPEAT E TIMES (
    INCREASE E
	INCREASE E
	INCREASE E
	INCREASE E
	INCREASE E
	INCREASE E
	INCREASE E
	INCREASE E
	INCREASE E
)
REPEAT E TIMES (
    INCREASE E
	INCREASE E
	INCREASE E
	INCREASE E
	INCREASE E
)
REPEAT E TIMES (
    REPEAT Q TIMES (
		CLEAR A
		CLEAR B
        CLEAR C
		CLEAR J
        INCREASE A
        # Check for divisible by 2, output to C, A AND J
		REPEAT V TIMES (
			REPEAT A TIMES (
				CLEAR A
				INCREASE B
				INCREASE J
			)
			REPEAT C TIMES (
				CLEAR C
				INCREASE A
			)
			REPEAT B TIMES (
				CLEAR B
				INCREASE C
			)
		)
        REPEAT C TIMES ( # pariton, V = 3*V
			# Tässä laskemme seuraavan arvon, tulostamme sen, jonka jälkeen lasketaaan myös toisiksi seuraavan arvon ja asetetaan se V:ksi
			CLEAR N
			REPEAT V TIMES (
				INCREASE N
				INCREASE N
				INCREASE N
			)
			INCREASE N
			# Nyt N on yhtä suuri kuin nykyinen tarvittava elementti
			REPEAT J TIMES ( # Lisätään siihen J niin saadaan sitä seuraava arvo, J on tässä vaiheessa puolet arvosta (ensimmäisestä aloittaen)
                INCREASE V
            )
			PRINT N
        )
        REPEAT A TIMES ( # parillinen, V = V / 2
			CLEAR V
			CLEAR O
			CLEAR U
			INCREASE U
            REPEAT J TIMES (
			    INCREASE V
				
				# Määritetään, että täytyykö jatkaa tulostamista (onko V = 1)
				REPEAT U TIMES ( # Runs on first
					REPEAT O TIMES ( # Runs on second ( V > 1 ), sets Q = 1
						INCREASE Q
						CLEAR U
					)
					REPEAT U TIMES (
						CLEAR Q
						INCREASE O
					)
				)
            )
        )
        PRINT V
    )
)

Test details

Test 1 (public)

Verdict: ACCEPTED

input
(empty)

correct output
(empty)

user output
# Checking if it is one should...

Feedback: 446 tests processed (command limit exceeded)