Re: Is there a difference between python

2020-04-05 Thread Eryk Sun
On 4/5/20, Malcolm Greene wrote: > Is there a difference between the following 2 ways to launch a console-less > script under Windows? > > python

Re: Exceptions versus Windows ERRORLEVEL

2020-04-05 Thread Eryk Sun
On 4/3/20, Stephen Tucker wrote: > > Does an exception raised by a Python 3.x program on a Windows machine set > ERRORLEVEL? ERRORLEVEL is an internal state of the CMD shell. It has nothing to do with Python. If Python exits due to an unhandled exception, the process exit code will be 1. If CMD w

Re: Is there a difference between python

2020-04-05 Thread David L Neil via Python-list
On 6/04/20 10:35 AM, Malcolm Greene wrote: Is there a difference between the following 2 ways to launch a console-less script under Windows? python

Re: Is there a difference between python

2020-04-05 Thread Mike Dewhirst
On 6/04/2020 8:35 am, Malcolm Greene wrote: Is there a difference between the following 2 ways to launch a console-less script under Windows? python

Is there a difference between python

2020-04-05 Thread Malcolm Greene
Is there a difference between the following 2 ways to launch a console-less script under Windows? python

Re: how to specify trusted hosts in windows config file

2020-04-05 Thread dcwhatthe
On Sunday, April 5, 2020 at 2:15:21 PM UTC-4, Peter J. Holzer wrote: > --yrj/dFKFPuw6o+aM > Content-Type: text/plain; charset=us-ascii > Content-Disposition: inline > Content-Transfer-Encoding: quoted-printable > > On 2020-03-31 08:35:35 +1100, Chris Angelico wrote: > > On Tue, Mar 31, 2020 at 8:2

Re: python script to give a list of prime no.

2020-04-05 Thread Dan Sommers
On Sun, 05 Apr 2020 19:46:00 +0200 Pieter van Oostrum wrote: > Sathvik Babu Veligatla writes: > > > hi, > > I am new to python, and i am trying to output the prime numbers > > beginning from 3 and i cannot get the required output. It stops > > after giving the output "7" and that's it. > > COD

Re: python script to give a list of prime no.

2020-04-05 Thread Pieter van Oostrum
Sathvik Babu Veligatla writes: > hi, > I am new to python, and i am trying to output the prime numbers beginning > from 3 and i cannot get the required output. > It stops after giving the output "7" and that's it. > > CODE: > a = 3 > l = [] > while True: > for i in range(2,a): > if a

Re: python script to give a list of prime no.

2020-04-05 Thread Sathvik Babu Veligatla
On Sunday, April 5, 2020 at 8:03:19 PM UTC+5:30, inhahe wrote: > On Sun, Apr 5, 2020 at 8:26 AM Sathvik Babu Veligatla < > sathvikveliga...@gmail.com> wrote: > > > hi, > > I am new to python, and i am trying to output the prime numbers beginning > > from 3 and i cannot get the required output. > >

Re: python script to give a list of prime no.

2020-04-05 Thread Sathvik Babu Veligatla
On Sunday, April 5, 2020 at 8:03:19 PM UTC+5:30, inhahe wrote: > On Sun, Apr 5, 2020 at 8:26 AM Sathvik Babu Veligatla < > sathvikveliga...@gmail.com> wrote: > > > hi, > > I am new to python, and i am trying to output the prime numbers beginning > > from 3 and i cannot get the required output. > >

Re: Adding tkinter modules to notebook tabs [RESOLVED]

2020-04-05 Thread Rich Shepard
On Sat, 4 Apr 2020, Christian Gollwitzer wrote: Add that thing instead of the frame. blabla=BioDataForm() # whatever args it needs, maybe parent=nb nb.add(blabla, text="Biodata") Christian, This clarifies my uncertainty and answers my question. Thanks. PS: I suggest to change all Tk widget

Fwd: python script to give a list of prime no.

2020-04-05 Thread inhahe
On Sun, Apr 5, 2020 at 8:26 AM Sathvik Babu Veligatla < sathvikveliga...@gmail.com> wrote: > hi, > I am new to python, and i am trying to output the prime numbers beginning > from 3 and i cannot get the required output. > It stops after giving the output "7" and that's it. > > CODE: > a = 3 > l =

Re: python script to give a list of prime no.

2020-04-05 Thread Peter J. Holzer
On 2020-04-05 05:22:45 -0700, Sathvik Babu Veligatla wrote: > I am new to python, and i am trying to output the prime numbers > beginning from 3 and i cannot get the required output. It stops after > giving the output "7" and that's it. A technique I learned when I started programming (back in the

Re: python script to give a list of prime no.

2020-04-05 Thread Barry Scott
> On 5 Apr 2020, at 14:08, Sathvik Babu Veligatla > wrote: > > On Sunday, April 5, 2020 at 6:09:04 PM UTC+5:30, Chris Angelico wrote: >> On Sun, Apr 5, 2020 at 10:26 PM Sathvik Babu Veligatla >> wrote: >>> >>> hi, >>> I am new to python, and i am trying to output the prime numbers beginning

Windows python 3.8 module finder problem.

2020-04-05 Thread Barry Scott
I have code that uses the modulefinder: mf = modulefinder.ModuleFinder() mf.run_script( self.main_program ) with python 3.7 all works without problems. But python 3.8 tracebacks (TB), here is the end of the TB: File "C:\Python38.Win64\lib\modulefinder.py", line 326, in

Re: python script to give a list of prime no.

2020-04-05 Thread Sathvik Babu Veligatla
On Sunday, April 5, 2020 at 6:09:04 PM UTC+5:30, Chris Angelico wrote: > On Sun, Apr 5, 2020 at 10:26 PM Sathvik Babu Veligatla > wrote: > > > > hi, > > I am new to python, and i am trying to output the prime numbers beginning > > from 3 and i cannot get the required output. > > It stops after gi

Re: python script to give a list of prime no.

2020-04-05 Thread Sathvik Babu Veligatla
On Sunday, April 5, 2020 at 6:04:20 PM UTC+5:30, Orges Leka wrote: > You can try the following: > It is based on trial division and very slow, compared to the state of the > art: > > import math > def is_prime(n): > if int(math.sqrt(n))**2 == n: > return(False) > for i in range(2,i

Re: Adding tkinter modules to notebook tabs

2020-04-05 Thread Rich Shepard
On Sat, 4 Apr 2020, Terry Reedy wrote: IDLE's currently-working Settings dialog uses a ttl.Notebook with 5 tabs. To see it, run IDLE and on the top menu, select Options => Configure IDLE. Each tab displays a ttk.Frame with multiple widgets. Where there is a choice, ttk widgets are used. They ma

Re: python script to give a list of prime no.

2020-04-05 Thread Chris Angelico
On Sun, Apr 5, 2020 at 10:35 PM Orges Leka wrote: > > You can try the following: > It is based on trial division and very slow, compared to the state of the > art: > I think it's more helpful to assist the OP in learning coding, rather than provide a completely different function to do a similar

Re: python script to give a list of prime no.

2020-04-05 Thread Chris Angelico
On Sun, Apr 5, 2020 at 10:26 PM Sathvik Babu Veligatla wrote: > > hi, > I am new to python, and i am trying to output the prime numbers beginning > from 3 and i cannot get the required output. > It stops after giving the output "7" and that's it. > > CODE: > a = 3 > l = [] > while True: > for

Re: python script to give a list of prime no.

2020-04-05 Thread Orges Leka
You can try the following: It is based on trial division and very slow, compared to the state of the art: import math def is_prime(n): if int(math.sqrt(n))**2 == n: return(False) for i in range(2,int(math.ceil(math.sqrt(n: if n%i==0: return(False) return

python script to give a list of prime no.

2020-04-05 Thread Sathvik Babu Veligatla
hi, I am new to python, and i am trying to output the prime numbers beginning from 3 and i cannot get the required output. It stops after giving the output "7" and that's it. CODE: a = 3 l = [] while True: for i in range(2,a): if a%i == 0: l.append(1) else:

Re: how to specify trusted hosts in windows config file

2020-04-05 Thread Chris Angelico
On Sun, Apr 5, 2020 at 8:22 PM Peter J. Holzer wrote: > > On 2020-03-31 08:35:35 +1100, Chris Angelico wrote: > > On Tue, Mar 31, 2020 at 8:21 AM wrote: > > > For pypi.org alone, my dns lookup differs from yours: 151.101.128.223. > > > > Ahh, I think I see what's happening. Something's interferi

Re: how to specify trusted hosts in windows config file

2020-04-05 Thread Peter J. Holzer
On 2020-03-31 08:35:35 +1100, Chris Angelico wrote: > On Tue, Mar 31, 2020 at 8:21 AM wrote: > > For pypi.org alone, my dns lookup differs from yours: 151.101.128.223. > > Ahh, I think I see what's happening. Something's interfering with your > DNS - that's a Fastly IP address. The four address