RE: Relatively prime integers in NumPy

2024-07-12 Thread AVI GROSS via Python-list
Dmitry, Efficiency of several kinds is hotly debated and sometimes it depends a lot on what is done within loops. Many suggest a mild speed up of some comprehensions over loops but the loops are not gone but somewhat hidden and perhaps some aspects are faster for having been written in

RE: Relatively prime integers in NumPy

2024-07-12 Thread AVI GROSS via Python-list
Dmitry, I clearly did not understand what you wanted earlier as you had not made clear that in your example, you already had progressed to some level where you had the data and were now doing a second step. So, I hesitate to say much until either nobody else addressed the issue (as clearly

RE: Relatively prime integers in NumPy

2024-07-11 Thread AVI GROSS via Python-list
OK. That explains a bit more. If I understand what you are looking for is a fast implementation and quite often in Pyhon it means using code written in another language such as C that is integrated carefully in a moule or two. Another tack is to replace many explicit loops with often much

RE: Relatively prime integers in NumPy

2024-07-11 Thread AVI GROSS via Python-list
Дмитрий, You may think you explained what you wanted but I do not see what result you expect from your examples. Your request is a bit too esoteric to be a great candidate for being built into a module like numpy for general purpose se but I can imagine it could be available in modules build on

RE: Anonymous email users

2024-06-24 Thread AVI GROSS via Python-list
This discussion has wandered far from my original mention that I found it hard to reply to people using an invalid email address. I see no real connection to python except insofar as at least one spam-filter mentioned is written in python! Just to add an observation, the people writing here have

RE: [Tutor] How to go about a simple object grabbing in python (given coordinates of arms and objects)

2024-06-24 Thread AVI GROSS via Python-list
Marc, Several people have supplied feedback on whether your request is a good fit for here. Ultimately it is up to the owner/moderator. In particular, your request to the Tutor List may not fit the purpose and be a bit complex and to the main Python List also outside some common usage whether

RE: Anonymous email users

2024-06-17 Thread AVI GROSS via Python-list
It seems clear we have people on mailing lists that see it as a purely public forum, and that is fine for them. I have found plenty of times I choose not to continue in public and waste time for people as in this reply on a topic I raised and now will move away from. I have in the past, for

RE: Anonymous email users

2024-06-17 Thread AVI GROSS via Python-list
Thanks, Marco, for explaining. I, personally, have no interest in finding out who people are in this case. I simply am thinking that people who do not allow me to easily reply to them directly, should be ignored by me and not get my cooperation that way. I do understand reasons people use fake

Anonymous email users

2024-06-14 Thread AVI GROSS via Python-list
I notice that in some recent discussions, we have users who cannot be replied to directly as their email addresses are not valid ones, and I believe on purpose. Examples in the thread I was going to reply to are: henha...@devnull.tb

RE: Couldn't install numpy on Python 2.7

2024-06-12 Thread AVI GROSS via Python-list
Chris, You seem to have perceived an insult that I remain unaware of. I have no special knowledge, like you do, of plans made for changes to the pthon language and implementation. I was asking a hypothetical question about what some users would do if python came out with a newer major version.

RE: Couldn't install numpy on Python 2.7

2024-06-12 Thread AVI GROSS via Python-list
Chris, I don't want to get off message and debate whether my "jokes" are jokes, let alone funny. Obviously, they often aren't. What I meant by joking here does seem relevant. As the years pass, there can come a time when it is suggested that a language (any language including python) is no

RE: Couldn't install numpy on Python 2.7

2024-06-12 Thread AVI GROSS via Python-list
: Couldn't install numpy on Python 2.7 On Thu, 13 Jun 2024 at 03:41, AVI GROSS via Python-list wrote: > > Change is hard even when it may be necessary. > > The argument often is about whether some things are necessary or not. > > Python made a decision but clearly not a unanimous o

RE: Couldn't install numpy on Python 2.7

2024-06-12 Thread AVI GROSS via Python-list
Of MRAB via Python-list Sent: Wednesday, June 12, 2024 12:56 PM To: python-list@python.org Subject: Re: Couldn't install numpy on Python 2.7 On 2024-06-12 17:31, AVI GROSS via Python-list wrote: > I am sure there is inertia to move from an older product and some people > need a reason like this

RE: Couldn't install numpy on Python 2.7

2024-06-12 Thread AVI GROSS via Python-list
I am sure there is inertia to move from an older product and some people need a reason like this where the old becomes untenable. It seems Microsoft is having a problem where something lik 2/3 of Windows users have not upgraded from Windows 10 after many years and have set a deadline in a year or

RE: in Python? -- Chunk -- (ChunkC '(a a b b b)), ==> ((a 2) (b 3))

2024-06-11 Thread AVI GROSS via Python-list
Rob, That is a fairly straightforward and elegant solution if using an added mode called itertools. I went a different way by creating my own focused iterator and calling it, when needed, to produce one or the other of the results requested in the functions named chunk() and chunkc(). But

RE: in Python? -- Chunk -- (ChunkC '(a a b b b)), ==> ((a 2) (b 3))

2024-06-10 Thread AVI GROSS via Python-list
> i was just curiuos about simple, clever way to write it in Python It depends on what you mean by "clever". For some, it was like a suggestion on using something already available such as itertools.groupby, perhaps even better if it is actually compiled in from a language like C and perhaps

RE: in Python? -- Chunk -- (ChunkC '(a a b b b)), ==> ((a 2) (b 3))

2024-06-09 Thread AVI GROSS via Python-list
I remembered that HenHanna had been hard to deal with in the past and when my reply to him/her/them bounced as a bad/fake address it came back to me that I am better off not participating in this latest attempt to get us to perform then probably shoot whatever we say down. A considerate person

RE: in Python? -- Chunk -- (ChunkC '(a a b b b)), ==> ((a 2) (b 3))

2024-06-09 Thread AVI GROSS via Python-list
HH, Before bothering, it might be helpful if you spelled out a bit more in the way of requirements that would satisfy you and perhaps show your attempts. Your examples suggest it would be fairly simple to create an iterator, for example, that would yield as it examined one item at a time until

RE: From JoyceUlysses.txt -- words occurring exactly once

2024-06-08 Thread AVI GROSS via Python-list
I agree with Larry that the OP was asking something that might be fair to use in an interview process where perhaps an exact answer is not as important as showing how the person thinks about a process. The original question can be incomplete or vague. Do they give up? Do they ask careful

RE: From JoyceUlysses.txt -- words occurring exactly once

2024-06-08 Thread AVI GROSS via Python-list
Agreed, Thomas. As someone who has spent lots of time writing code OR requirements of various levels or having to deal with the bugs afterwards, there can be a huge disconnect between the people trying to decide what to do and the people having to do it. It is not necessarily easy to come

RE: From JoyceUlysses.txt -- words occurring exactly once

2024-06-04 Thread AVI GROSS via Python-list
>> Well.when using the file linux.words as a useful master list of >> "words".linux.words is strict ASCII The meaning of "words" depends on the context. The contents of the file mentioned are a minor attempt to capture a common subset of words in English but probably are not what

RE: Terminal Emulator

2024-05-14 Thread AVI GROSS via Python-list
The topic was to re-invent the wheel yet again and create a terminal emulator. I hesitate to say this but one approach is to consider the curses module as described by our very own Alan Gauld in a book: https://www.amazon.com/Programming-curses-Python-Alan-Gauld-ebook/dp/B091B85 B77 The topic

RE: A technique from a chatbot

2024-04-04 Thread AVI GROSS via Python-list
That is an excellent point, Mark. Some of the proposed variants to the requested problem, including mine, do indeed find all instances only to return the first. This can use additional time and space but when done, some of the overhead is also gone. What I mean is that a generator you create

RE: A technique from a chatbot

2024-04-03 Thread AVI GROSS via Python-list
: A technique from a chatbot On 4/3/2024 1:27 AM, AVI GROSS via Python-list wrote: > I am a tad confused by a suggestion that any kind of GOTO variant is bad. The suggestion runs counter to the reality that underneath it all, compiled programs are chock full of GOTO variants even for simple things l

RE: A missing iterator on itertools module?

2024-04-03 Thread AVI GROSS via Python-list
Antoon, Even if the suggested solution offers a partial result, you would need specific requirements to determine what should be done if one or more of the parts being cycled is shorter than the others. Stopping at that point is one option. Another is to continue but only interleave ones still

RE: A technique from a chatbot

2024-04-02 Thread AVI GROSS via Python-list
I am a tad confused by a suggestion that any kind of GOTO variant is bad. The suggestion runs counter to the reality that underneath it all, compiled programs are chock full of GOTO variants even for simple things like IF-ELSE. Consider the code here: >> def first_word_beginning_with_e( list_

Re: Multiplication

2024-04-01 Thread Avi Gross via Python-list
Is this a April 1 post for fools. Multiplication with an asterisk symbol is built into python. The same symbol used in other contexts has other contexts has an assortment of largely unrelated meanings such as meaning everything when used to import. On Mon, Apr 1, 2024, 1:27 PM Piergiorgio

RE: Can you help me with this memoization simple example?

2024-03-31 Thread AVI GROSS via Python-list
I am not sure if it was made clear that there is a general rule in python for what is HASHABLE and lists are changeable while tuples are not so the latter can be hashed as a simple copy of a list, albeit the contents must also be immutable. The memorize function uses a dictionary to store

RE: Popping key causes dict derived from object to revert to object

2024-03-25 Thread AVI GROSS via Python-list
Lori, The list comprehension you are thinking of does work if you change things a bit. But it is not a great idea as a main purpose of a dict is that using a hash means things are found in linear time. A comprehension iterates on all values. If you wanted to select just some items to keep in a

RE: Popping key causes dict derived from object to revert to object

2024-03-25 Thread AVI GROSS via Python-list
I am glad, Lori, you found a solution another way. Actually, Lori, I think you were right in looking for a built-in method that complements pop() by returning everything else other than the item mentioned. There are philosophical and practical considerations that were no doubt considered and a

RE: Popping key causes dict derived from object to revert to object

2024-03-22 Thread AVI GROSS via Python-list
Loris wrote: "Yes, I was mistakenly thinking that the popping the element would leave me with the dict minus the popped key-value pair. Seem like there is no such function." Others have tried to explain and pointed out you can del and then use the changed dict. But consider the odd concept of

RE: Configuring an object via a dictionary

2024-03-17 Thread AVI GROSS via Python-list
If we are bringing up other languages, let's return to what was part of the original question. How van a dictionary be used in python if your goal is to sort of use it to instantiate it into a set of variables and values inside the local or global or other namespaces? Can we learn anything

RE: Configuring an object via a dictionary

2024-03-15 Thread AVI GROSS via Python-list
A part of the Python view of the world is about a concept of whether something is "truthy" or not and thus many corners of the language do not care what kind of object an expression returns. If the object is returned in a context looking for not a Boolean value but a truth value, it is evaluated

RE: Extract lines from file, add to new files

2024-02-03 Thread AVI GROSS via Python-list
Dave, You and I have had some experience in teaching or tutoring others and I think it fair to say our motivation is closer to teaching someone how they can fish for themselves rather than just handing them a fully-cooked fish. My favorite kinds of questions, thus, include someone who explains

RE: Extract lines from file, add to new files

2024-02-03 Thread AVI GROSS via Python-list
We substantially agree with that, Thomas. In the best of all possible worlds, someone who gets stuck will sit down and try to carefully spell out things in ways like you mention and, incidentally, may often catch the error or figure out how to do it and not even send in a request! LOL! I think a

RE: Extract lines from file, add to new files

2024-02-03 Thread AVI GROSS via Python-list
Thomas, I have been thinking about the concept of being stingy with information as this is a fairly common occurrence when people ask for help. They often ask for what they think they want while people like us keep asking why they want that and perhaps offer guidance on how to get closer to what

RE: Extract lines from file, add to new files

2024-02-03 Thread AVI GROSS via Python-list
This discussion has circled back to where it started. It illustrates quite a few points about how many different ways someone can do something as well as doing it using different tools and also about how others may see aspects of mission creep as they look for making it perfect when it need not

RE: Extract lines from file, add to new files

2024-01-30 Thread AVI GROSS via Python-list
Thomas, on some points we may see it differently. Some formats can be done simply but are maybe better done in somewhat standard ways. Some of what the OP has is already tables in a database and that can trivially be exported into a CSV file or other formats like your TSV file and more. They can

RE: Aw: Re: Extract lines from file, add to new files

2024-01-30 Thread AVI GROSS via Python-list
Rich, You may want to broaden your perspective a bit when people make suggestions. Karsten did not spell out a full design and should not need to. But consider this as a scenario. You want to send (almost) the same message to one or more recipients. So call a program, perhaps some variant on

RE: Extract lines from file, add to new files

2024-01-30 Thread AVI GROSS via Python-list
I deleted the contents of the message so I can avoid both of the deadly sins of top posting and bottom posting and chance committing the sin of replying without any context. Of course, I am only replying to Jon wishing a real or feigned good luck to the OP. But seriously, the OP, AKA Rich, is

RE: Extract lines from file, add to new files

2024-01-29 Thread AVI GROSS via Python-list
It can be quite frustrating figuring out what someone wants, Grant, especially when they just change it. It is worse when instead of starting a new thread with an appropriate subject line, it continues and old one that was also frustrating to understand. It sounds though like another attempt to

RE: Extract lines from file, add to new files

2024-01-29 Thread AVI GROSS via Python-list
Rich, You got an overly general reply to a question many of us may not understand. You have not hinted at how the two files are organized, perhaps with an example. There are several general solutions that may apply. Some involve reading in both files into data structures and perhaps linking

RE: extend behaviour of assignment operator

2024-01-19 Thread AVI GROSS via Python-list
Guenther, It is best not to suggest a drastic fix for a more limited problem. As a general rule, many programming languages only have a pointer concept even vaguely along the lines you want for garbage collection purposes. An area of memory may have stored alongside it how many other things

RE: Extract lines from file, add to new files

2024-01-14 Thread AVI GROSS via Python-list
Whoa, Олег Сивоконь! I do not understand any arguments about whether comments are, or are not an object. From one perspective, python comments have even less meaning than whitespace and simply do not exist. I mean once a naked "#" is seen, the rest of that line is effectively discarded by the

RE: Extract lines from file, add to new files

2024-01-14 Thread AVI GROSS via Python-list
Straight Ahead, on average, I am not sure what your beef is as apparently it is always something else than some others assumed. If your point is that you want consistency, sure that would be nice. But maybe part of the inconsistency I am not sure you mean is an artifact of the language. There

RE: Extract lines from file, add to new files

2024-01-14 Thread AVI GROSS via Python-list
Chris, It gets frustrating when people demand too much when strictly speaking, it is not really needed or may cause new problems. How often do you really think anyone out there NEEDS to define a function in the context mentioned? You provided a way to create an anonymous function and that was

RE: Extract lines from file, add to new files

2024-01-14 Thread AVI GROSS via Python-list
It can be worth considering why a language is designed or altered in certain ways to see if there was a tradeoff that made it seem worthwhile or easier than some other choice. Python grew and there was regular pressure to add keywords which might break existing programs. So, yes, sometimes, a

RE: Extract lines from file, add to new files

2024-01-12 Thread AVI GROSS via Python-list
If the data in the input file is exactly as described and consists of alternating lines containing a name and email address, or perhaps an optional blank line, then many solutions are possible using many tools including python programs. But is the solution a good one for some purpose? The two

RE: A problem with str VS int.

2023-12-12 Thread AVI GROSS via Python-list
Roel, I sent a similar reply in private to someone who may not be listening as their mind is made up. This points to a serious problem with people not testing hypotheses adequately. Perhaps for homework, we can assign a request for a Python program that creates a random sample of quite a few

RE: A problem with str VS int.

2023-12-09 Thread AVI GROSS via Python-list
Steve, I would say converting to a number, as you eventually did, is the way to go. When you compare character strings, it will not be in numeric order. Compare "80" with "400" and since 8 is greater than 4, the comparison is over and "80" is greater then "40" even though 80 is way less than

RE: Newline (NuBe Question)

2023-11-27 Thread AVI GROSS via Python-list
Dave, I gave an example, again, and make no deep claims so your comments may be valid, without any argument. I mentioned CSV and a related family such as TSV as they were a common and simple data format that has long been used. There are oodles of others and yes, these days many people can

RE: Newline (NuBe Question)

2023-11-26 Thread AVI GROSS via Python-list
Dave, Back on a hopefully more serious note, I want to make a bit of an analogy with what happens when you save data in a format like a .CSV file. Often you have a choice of including a header line giving names to the resulting columns, or not. If you read in the data to some structure, often

RE: Newline (NuBe Question)

2023-11-26 Thread AVI GROSS via Python-list
Isn't it fascinating that a meaningless piece of code used to illustrate something can be analyzed as if it was full of malicious content? Yes, my choice of names was as expected. The numbers chosen had no special meaning other than choosing one number in each of three equivalence classes. But,

RE: RE: Newline (NuBe Question)

2023-11-26 Thread AVI GROSS via Python-list
Just FYI, I deliberately chose that abbreviation for a sort of irony as for some people college is about almost anything except learning and some people think they are studs and just party and ... And I am very tired of gender discussions. Lots of words now include two or even more genders.

RE: RE: Newline (NuBe Question)

2023-11-26 Thread AVI GROSS via Python-list
That is an entirely different discussion, Michael. I do not know what ideas Guido had ages ago and where he might stand now and I actually seriously disagree with the snippet you quoted below. Python was started long ago as a way to improve in some ways on what was there before. Some of the

RE: Newline (NuBe Question)

2023-11-24 Thread AVI GROSS via Python-list
Grizz[l]y, I think the point is not about a sorted list or sorting in general It is about reasons why maintaining a data structure such as a list in a program can be useful beyond printing things once. There are many possible examples such as having a list of lists containing a record where the

RE: Code improvement question

2023-11-17 Thread AVI GROSS via Python-list
Many features like regular expressions can be mini languages that are designed to be very powerful while also a tad cryptic to anyone not familiar. But consider an alternative in some languages that may use some complex set of nested function calls that each have names like match_white_space(2,

RE: xor operator (DEPRECATED)

2023-11-13 Thread AVI GROSS via Python-list
’t require predicates. b) I welcome any thoughts on this. DG > On 14 Nov 2023, at 04:27, AVI GROSS via Python-list > wrote: > > I was going to ask a dumb question. Has any other language you know of made > something available that does what is being asked for and included it in the &

RE: xor operator

2023-11-13 Thread AVI GROSS via Python-list
I was going to ask a dumb question. Has any other language you know of made something available that does what is being asked for and included it in the main program environment rather than an add-on? A secondary mention here has been whether short-circuiting functions like "any" and "all" have

RE: Checking if email is valid

2023-11-07 Thread AVI GROSS via Python-list
Text messages have taken a nasty turn and especially now that so many people have unlimited messages per month in their plan. People overuse them to the point where I opt out of some things like my home town notifications as they bombard me with other things I am not interested in. A major

RE: Python Golf

2023-11-07 Thread AVI GROSS via Python-list
Discussions like this feel a bit silly after a while. How long something is to type on a command line is not a major issue and brevity can lead to being hard to remember too especially using obscure references. Consider that the Perl version as shown below does not need to import anything. If

RE: Checking if email is valid

2023-11-06 Thread AVI GROSS via Python-list
Just mildly noticing the topics discussed have wandered quite a bit away from Python, let alone even programming. Phone numbers are not what they used to be. They tend to be quite portable and in some ways can be chained so my house phone rings through to my cell phone but a text will not be

RE: Checking if email is valid

2023-11-05 Thread AVI GROSS via Python-list
Grant (and others), I am asking about the overall programming process of dealing with email addresses beyond checking the string for some validity. You mentioned requiring you type in your email twice as one example. I generally do a copy/paste to avoid typing or have my browser fill it in.

RE: Checking if email is valid

2023-11-03 Thread AVI GROSS via Python-list
addresses. -Original Message- From: Python-list On Behalf Of Chris Angelico via Python-list Sent: Friday, November 3, 2023 1:43 AM To: python-list@python.org Subject: Re: Checking if email is valid On Fri, 3 Nov 2023 at 12:21, AVI GROSS via Python-list wrote: > My guess is that a first t

RE: Checking if email is valid

2023-11-02 Thread AVI GROSS via Python-list
I have never had a need to check email but in my reading over the years, I am aware of modules of multiple kinds you can use to do things like parsing dates, URL and email addresses and probably many other such things into some kind of object and then you can use aspects of the object to do

RE: Checking if email is valid

2023-11-02 Thread AVI GROSS via Python-list
via Python-list Sent: Thursday, November 2, 2023 2:05 AM To: python-list@python.org Subject: Re: Checking if email is valid On Thu, 2 Nov 2023 at 15:20, AVI GROSS via Python-list wrote: > > Yes, it would be nice if there was a syntax for sending a test message sort > of li

RE: Checking if email is valid

2023-11-01 Thread AVI GROSS via Python-list
Yes, it would be nice if there was a syntax for sending a test message sort of like an ACK that is not delivered to the recipient but merely results in some status being sent back such as DELIVERABLE or NO SUCH USER or even MAILBOX FULL. An issue with the discussion that may be worth considering

RE: Question(s)

2023-10-26 Thread AVI GROSS via Python-list
: Thursday, October 26, 2023 6:50 PM To: python-list@python.org Subject: Re: Question(s) On 10/26/2023 6:36 PM, AVI GROSS via Python-list wrote: > I am not one for IDLE worship, Tenor. But if you have been getting a message here, it is that there are an amazing number of programs that support your

RE: Question(s)

2023-10-26 Thread AVI GROSS via Python-list
I am not one for IDLE worship, Tenor. But if you have been getting a message here, it is that there are an amazing number of programs that support your use of python during the development phase and perhaps later. I actually often use an environment called RSTUDIO (now part of a new name of

RE: Question(s)

2023-10-25 Thread AVI GROSS via Python-list
Just want to add that even when you can prove that an algorithm works absolutely positively, it will often fail on our every finite computers. Consider families of algorithms that do hill climbing to find a minimum and maximum and are guaranteed to get ever closer to a solution given infinite

RE: Question(s)

2023-10-25 Thread AVI GROSS via Python-list
ubject: Re: Question(s) On Tue, Oct 24, 2023 at 9:36 PM AVI GROSS via Python-list wrote: > > Agreed, Chris. There are many methods way better than the sort of RAID > architecture I supplied as AN EXAMPLE easy to understand. But even so, if a > hard disk or memory chip is fried or a nuclear bomb

RE: Question(s)

2023-10-24 Thread AVI GROSS via Python-list
, 2023 9:41 PM To: python-list@python.org Subject: Re: Question(s) On Wed, 25 Oct 2023 at 12:20, AVI GROSS via Python-list wrote: > Consider an example of bit rot. I mean what if your CPU or hard disk has a location where you can write a byte and read it back multiple times and sometimes get the wr

RE: Question(s)

2023-10-24 Thread AVI GROSS via Python-list
Whoa! The question cannot be about whether it is possible to prove any abstract program will be correct and especially not on real hardware that can fail in various ways or have unexpected race conditions or interacts with other places such as over the internet. It has been quite well proven

RE: Where I do ask for a new feature

2023-10-20 Thread AVI GROSS via Python-list
I still see no great reason for a new feature here and the namespace issue has often been discussed. You can always opt to create your own namespace of some sort and make many of your variables within it and always refer to the variables explicitly so the only collisions that can happen are

RE: Where I do ask for a new feature

2023-10-19 Thread AVI GROSS via Python-list
Bongo, Variables in most programming languages either have to be removed manually or allowed to drift outside a boundary when they disappear for scoping reasons and perhaps are garbage collected at some point. There are many ways to make transient variables that disappear at some time and do we

RE: Postgresql equivalent of Python's timeit?

2023-09-17 Thread AVI GROSS via Python-list
Timing things that are fairly simple is hard enough to do repeatedly, but when it involves access to slower media and especially to network connections to servers, the number of things that can change are enormous. There are all kinds of caching at various levels depending on your hardware and

RE: Fwd: AUTO EDITOR DIDN'T WORK

2023-06-13 Thread AVI GROSS via Python-list
I think it is time to ask this topic to go find some other place to talk to itself. I have seen NO reason to think any question about problems with Python has been asked. Not properly. It sounds like someone messed up an installation, perhaps of other programs like an editor and some

Re: what's the problem??????

2022-07-13 Thread Avi Gross via Python-list
Nati, This is a two-way process and requires you to be very clear on what is not working or what you are trying to do or help clear away having us try to understand lots of code that is not very related to the question. Your code, as shown, makes an empty string repeatedly in a loop.  a=dict() I

Re: NILEARN - WHY THIS CODE THROWS AN ERROR?????

2022-07-08 Thread Avi Gross via Python-list
Nati Stern has asked several questions here, often about relatively technical uses of python code that many of us have never used and still is not providing more exact info that tends to be needed before anyone can even think of diagnosing the problem. I have learned to stay away from some

Re: "CPython"

2022-06-24 Thread Avi Gross via Python-list
David, I understand now. As a project for your own edification I can understand it, albeit it is a more substantial effort than many people might choose, LOL! So unless it starts being used heavily and adopted by some organization, the result of your effort will not necessarily be compatible

Re: "CPython"

2022-06-23 Thread Avi Gross via Python-list
David, I am curious why you are undertaking the effort to take a language already  decades old and showing signs of being a tad rusty into a language that suggests further oxidation. More seriously, I am interested in what this can gain and the intended user  base. I studied Rust for a while and

Re: "CPython"

2022-06-21 Thread Avi Gross via Python-list
If we want to be humorous, RPython would obviously either be written in R, which really is not designed well for such purposes, or would be some kind of synthesis that already exists that allows you to run R and python code interchangeably on sort of shared data that I sometimes do in RSTUDIO.

Re: "CPython"

2022-06-20 Thread Avi Gross via Python-list
This leads to the extremely important question of what would an implementation of Python, written completely in C++, be called? C++Python CPython++ C+Python+ DPython SeaPython? SeeSeaSiPython I don't even want to think fo what sound a C# Python would make. OK, my apologies to all. Being an

Re: fill out bulletins

2022-06-14 Thread Avi Gross via Python-list
I wish this discussion was simplified. It sounds to me like what is wanted is a way to PRINT a filled-out form using some dynamic text that fits over designated slots in the data. It is not that different from many other tasks where you overlay some graphics with text. You need a decent version

Re: Function to Print a nicely formatted Dictionary or List?

2022-06-09 Thread Avi Gross via Python-list
Dave, Despite your other programming knowledge, I suspect you think this is the forum where people come to be tutored. Try here: https://mail.python.org/mailman/listinfo/tutor Yes, there are plenty of pretty printers available and you can build your own function fairly easily. A module like

Re: How to test characters of a string

2022-06-09 Thread Avi Gross via Python-list
Dave, Sometimes a task is done faster by NOT programming anything in any language! Not only have you spent a lot of your own time but many dozens of messages here have dragged in others, who gain nothing ;-) The domain you are operating in seems to have lots of variants in how the titles are

Re: How to replace characters in a string?

2022-06-08 Thread Avi Gross via Python-list
Dave, Your goal is to compare titles and there can be endless replacements needed if you allow the text to contain anything but ASCII. Have you considered stripping out things instead? I mean remove lots of stuff that is not ASCII in the first place and perhaps also remove lots of extra

Re: How to test characters of a string

2022-06-07 Thread Avi Gross via Python-list
Amazing how some people bring out the heavy artillery, first! LOL! If the question was how to remove any initial digits and perhaps whitespace in a string, it is fairly easy to do without any functions to test if there are digits before the title. I mean look at initial characters and move

Re: oop issue

2022-05-23 Thread Avi Gross via Python-list
invest_crypto.client_list.append(self) I am wondering about the phrasing above. When you are in the dunder init function, you normally create and change items in YOURSELF so why is your code not changing self.crypto_client_list? And what are you appending to before ever creating it? Would it

Re: .0 in name

2022-05-13 Thread Avi Gross via Python-list
You left out 3CPO, Dave. Names with numerals are not unreasonable in some circumstances. But programming languages are not a full spectrum of real life. They can have  reserved words too so you may not be able to use "while" and if you choose to create a function that masks another, you cannot

Re: .0 in name

2022-05-13 Thread Avi Gross via Python-list
 ❽ -Original Message----- From: Avi Gross via Python-list To: python-list@python.org Sent: Fri, May 13, 2022 6:02 pm Subject: Re: .0 in name Bryan, As has been pointed out, it is very common in possibly all programming languages to not allow digits at the start of many identifiers. It make

Re: .0 in name

2022-05-13 Thread Avi Gross via Python-list
Bryan, As has been pointed out, it is very common in possibly all programming languages to not allow digits at the start of many identifiers. It makes it hard to parse for numbers which tend to start with digits. Some languages even have special rules on not starting a number with a zero unless

Re: tail

2022-05-11 Thread Avi Gross via Python-list
This seems to be a regular refrain where someone wants something as STANDARD in a programming language or environment and others want to keep it lean and mean or do not see THIS suggestion as particularly important or useful. Looking at the end of something is extremely common. Packages like

Re: tail

2022-05-11 Thread Avi Gross via Python-list
Just FYI, UNIX had a bunch of utilities that could emulate a vanilla version of tail on a command line. You can use sed, awk and quite a few others to simply show line N to the end of a file or other variations.  Of course the way many things were done back then had less focus on efficiency

Re: tail

2022-05-07 Thread Avi Gross via Python-list
Marco, I think it was made clear from the start that "text" files in the classic sense have no random access method at any higher level than reading a byte at some offset from the beginning of the file, or back from the end when it has not grown. The obvious fact is that most of the time the

Re: Python/New/Learn

2022-05-06 Thread Avi Gross via Python-list
This topic has rapidly shifted over way beyond Python even as the original  person has not returned to participate. There are many ways to teach anything and since the classical method was to learn in person from someone using mainly sound or pantomime, it has hung on. Even with the existence

Re: Python/New/Learn

2022-05-05 Thread Avi Gross via Python-list
Before more people reply to this user, I note I have not seen them reply back to the list about any questions or comments others have taken the time to provide. My warning bells go off when I see patterns and there was a similar request from another gmail account to an R language forum I am

Re: Python/New/Learn

2022-05-04 Thread Avi Gross via Python-list
I agree Chris that the Ukrainian Python Books are daunting as I barely started learning that language now even though my early years were just a few miles away and I might even have relatives still there! But as has been pointed out, suggestions are more helpful if you know a bit more about

Re: Python/New/Learn

2022-05-04 Thread Avi Gross via Python-list
@python.org Sent: Wed, May 4, 2022 11:02 pm Subject: Re: Python/New/Learn On Thu, 5 May 2022 at 12:57, Avi Gross via Python-list wrote: > > https://wiki.python.org/moin/PythonBooks > That's an incredibly daunting list, and not something I'd overly strongly recommend, but yes, if you want to g

Re: Python/New/Learn

2022-05-04 Thread Avi Gross via Python-list
https://wiki.python.org/moin/PythonBooks -Original Message- From: Patrick 0511 To: python-list@python.org Sent: Wed, May 4, 2022 9:36 pm Subject: Python/New/Learn Hello, I'm completely new here and don't know anything about python. Can someone tell me how best to start? So what things

  1   2   3   4   >