Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  newsreader  groups  login

Message-ID:  

It's hard to think of you as the end result of millions of years of evolution.


devel / comp.lang.python / code issue

SubjectAuthor
o code issueTola Oj

1
code issue

<mailman.183.1650560501.20749.python-list@python.org>

 copy mid

https://www.novabbs.com/devel/article-flat.php?id=17953&group=comp.lang.python#17953

 copy link   Newsgroups: comp.lang.python
Path: i2pn2.org!i2pn.org!news.swapon.de!fu-berlin.de!uni-berlin.de!not-for-mail
From: ojomoolu...@gmail.com (Tola Oj)
Newsgroups: comp.lang.python
Subject: code issue
Date: Thu, 21 Apr 2022 18:01:32 +0100
Lines: 136
Message-ID: <mailman.183.1650560501.20749.python-list@python.org>
References: <CAD9v3sk7tCMuxGHGPObk_dxKSAjcw9JLwq_VvCFDNNSfU3vPRQ@mail.gmail.com>
Mime-Version: 1.0
Content-Type: text/plain; charset="UTF-8"
X-Trace: news.uni-berlin.de s09Z9jFbTT8yDInnlKMzJwqgM9OcH3vVbtDwMljaCTPw==
Return-Path: <ojomooluwatolami675@gmail.com>
X-Original-To: python-list@python.org
Delivered-To: python-list@mail.python.org
Authentication-Results: mail.python.org; dkim=pass
reason="2048-bit key; unprotected key"
header.d=gmail.com header.i=@gmail.com header.b=RWNoMFi8;
dkim-adsp=pass; dkim-atps=neutral
X-Spam-Status: OK 0.035
X-Spam-Evidence: '*H*': 0.93; '*S*': 0.00; '(which': 0.04; 'elif':
0.09; 'else:': 0.09; '13)': 0.16; 'inclusive,': 0.16; 'integer':
0.16; 'subject:code': 0.16; 'subject:issue': 0.16; 'to:addr
:python-list': 0.20; 'input': 0.21; 'code': 0.23; 'saying': 0.25;
'follows:': 0.26; 'output': 0.28; 'passes': 0.32; 'message-
id:@mail.gmail.com': 0.32; 'but': 0.32; "i'm": 0.33;
'received:google.com': 0.34; 'question.': 0.35;
'from:addr:gmail.com': 0.35; 'received:209.85': 0.37;
'received:209': 0.39; 'received:209.85.208': 0.39; 'both': 0.40;
'above': 0.62; 'range': 0.64; '8bit%:7': 0.67; 'per': 0.68;
'below': 0.69; 'me:': 0.91
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112;
h=mime-version:from:date:message-id:subject:to;
bh=khV8UG/k5foBKrtTkgXoom6v60Tb2bV9VO29muA7xK4=;
b=RWNoMFi8nYuaJj1wfI/m3qYRQt+N2h3JNK1Wy3WwqX8Xv7FxVvTPKYW7muAP29jpXX
23IcoqbX5Tq1z23JwvyyD/41+xfP2DAQ5sbM9npdXxuWqBRYHx+V8N8g+fZ99L9d2hL4
WCbcJT/Nvwwx1is7edF9atW1+WtQ67ICp7br0RtnXPfJvWC9pe7QSNTgxiFL3NKMnDoo
7gnv0GI0JEb6FEB/dbvMfWM8Sjax0+New9yWIt2/NzDEtG1s8SKJXWBEsXkOpw9NW0mW
EKlXvR4aLU07Bsf+C5FMXl20wCxAgMsEY4Bpbgm2ss489a6YM9DEnSPtJTBjIBWrb9L2
T7qA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=1e100.net; s=20210112;
h=x-gm-message-state:mime-version:from:date:message-id:subject:to;
bh=khV8UG/k5foBKrtTkgXoom6v60Tb2bV9VO29muA7xK4=;
b=dkVFjjUTmthlOO1Ccts0N2etF4t687Kxc9cvBBf79qhD3ve+ETB28d/Ae7+DZtzSdH
U+imH7i1rtGWoaTdDftNz8xYFDaVF/ahr9XSbSlorM4QIALMTcUS36rip7Ks3E4TfQm8
YHt5Il5UzEoHG5eiUGcBuioKy5maj6dLwG71nKHIYr8SSSg9MvpW4gFjPzFD9tBNV4iA
hwymu78KythyyuXBqbCM8cSKqzkIUQAncR5MsaZ3+dbXdOBw7TTbmdt4r6apR8MiYfmL
yOws/ts3ZPhYfloUj5hASGIxQelh2nqUwmpM5s3FkHV9k9J4dFSs2S6WLH/TGBNp9HRu
NFuA==
X-Gm-Message-State: AOAM532yOZLAIE7SjlKZP4NzH2xAwSofpXyJBGyqK3n52qWsBwtj+kUl
+OOAlYVO4KO4ttFUDOaDVzJTTsq3+ckyjrWy9KecNNhVfRk=
X-Google-Smtp-Source: ABdhPJzEoBBpNSDgWbNbUmJoSUa7PaBRWf1hL9RE9DXB2iJZShrL/f53kdVK+jURXWuTfgU+HZaiZ80f+VWuAomgR00=
X-Received: by 2002:a2e:808b:0:b0:24d:c2a4:3fc7 with SMTP id
i11-20020a2e808b000000b0024dc2a43fc7mr391372ljg.58.1650560499282; Thu, 21 Apr
2022 10:01:39 -0700 (PDT)
X-Content-Filtered-By: Mailman/MimeDel 2.1.39
X-BeenThere: python-list@python.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: General discussion list for the Python programming language
<python-list.python.org>
List-Unsubscribe: <https://mail.python.org/mailman/options/python-list>,
<mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive: <https://mail.python.org/pipermail/python-list/>
List-Post: <mailto:python-list@python.org>
List-Help: <mailto:python-list-request@python.org?subject=help>
List-Subscribe: <https://mail.python.org/mailman/listinfo/python-list>,
<mailto:python-list-request@python.org?subject=subscribe>
X-Mailman-Original-Message-ID: <CAD9v3sk7tCMuxGHGPObk_dxKSAjcw9JLwq_VvCFDNNSfU3vPRQ@mail.gmail.com>
 by: Tola Oj - Thu, 21 Apr 2022 17:01 UTC

given a number n, for each integer i in the range from 1 to n inclusive,
print one value per line as follows:
.. if i is a multiple of both 3 but not 5, print fizz.
..if i is a multiple of 5 but not 3, print buzz
..if i is not a multiple of 3 or 5, print the value of i.

the above is the question. the below is my answer, but it keeps saying I'm
failing it and this is the output my code keeps giving me: it passes my
input n (Which was 13) and starts to print from 1 again. please help

-

1

-

2

-

Fizz

-

4

-

Buzz

-

Fizz

-

7

-

8

-

Fizz

-

Buzz

-

11

-

Fizz

-

13

-

1

-

2

-

Fizz

-

4

-

Buzz

-

Fizz

-

7

-

8

-

Fizz

-

Buzz

-

11

-

Fizz

-

13

-

14

-

Fizzbuzz

for i in range(1, n+1):
if i % 3 == 0 and i % 5 == 0:
print("Fizzbuzz")
elif i % 3 == 0:
print("Fizz")
elif i % 5 == 0:
print("Buzz")
else:
print(i)
print(i, sep='\n')

fizzbuzz(13)

1
server_pubkey.txt

rocksolid light 0.9.7
clearnet tor