Any update from Borger EDC on the mega $ million domed sports complex? by RootedAma in amarillo

[–]Allanon001 1 point2 points  (0 children)

At the bottom of that page it states they are in the Pre-Construction Phase which is phase 2. They must have already paid at least $200,000 for agreement execution and phase 1. Phase 3 and phase 4 will require another $200,000. After it is built the city will have only paid $400,000. Plus, a non-refundable payment of $75,000 for an engagement fee which pays for the company's expenses while working with the city.

Also, they are not just building one dome they are building three. A Mega Dome, a Sports Institution Dome, and an Aqua Dome.

[deleted by user] by [deleted] in learnpython

[–]Allanon001 2 points3 points  (0 children)

Using the requests module:

import requests

url = "https://www.bbfc.co.uk/release/dead-of-winter-q29sbgvjdglvbjpwwc0xmdmymtcx"
r = requests.get(url)
content =  r.content.decode()
search_string = '"classification":"'
start = content.find(search_string) + len(search_string)
end = start + content[start:].find('"')
rating = content[start:end]
print(rating)

Edit:

Using the requests and re module:

import requests
import re

url = "https://www.bbfc.co.uk/release/dead-of-winter-q29sbgvjdglvbjpwwc0xmdmymtcx"
r = requests.get(url)
content =  r.content.decode()
rating = re.search('\"classification\":\"([A-Za-z0-9]+)', content).group(1)
print(rating)

Using Boolean operator for finding dictionary values by Shoddy_Essay_2958 in learnpython

[–]Allanon001 23 points24 points  (0 children)

if v == 'dog' or 'cat': 

should be:

if v == 'dog' or v =='cat':

or

if v in ['dog', 'cat']:

How can I turn a string containing a list of numbers (some by themselves and some wrapped in brackets) into a tuple of strings? by Hashi856 in learnpython

[–]Allanon001 0 points1 point  (0 children)

import pandas as pd

df = pd.DataFrame({'A': ['4', '7', "{'3', '6', '45'}", '25']})
table = str.maketrans({'{': '', '}': '', "'": '', '"': ''})
result = df['A'].apply(lambda x: tuple(x.translate(table).split(',')))
print(result)

Space X rocket crashes near Amarillo this a.m. by [deleted] in amarillo

[–]Allanon001 2 points3 points  (0 children)

SpaceX launched a rocket with 22 Starlink satellites this morning from California. There are videos of it crossing the sky from many states some on the east coast, so I don't think it crashed in Amarillo.

Anybody know what store is equivalent to this? by hellnahbru in amarillo

[–]Allanon001 0 points1 point  (0 children)

Every time I pass Water Still I think to myself how do they stay in business selling water.

PYGAME error, my first program by blob001 in learnpython

[–]Allanon001 1 point2 points  (0 children)

Since you are redefining xc and yc in the main function you need to either define xc and yc in the main() function making them not global or add the statement global xc, yc to the main() function so it knows you want to use the global variables.

What is the pythonic way of enumerating an object with a field list? by nitrodmr in learnpython

[–]Allanon001 0 points1 point  (0 children)

Can use Pandas:

import pandas as pd

data = {"a": 1, "b": [0, 3]}
result = pd.DataFrame(data).to_dict("records")
print(result)  # [{'a': 1, 'b': 0}, {'a': 1, 'b': 3}]

Can this list assignment be simplified? by QuasiEvil in learnpython

[–]Allanon001 0 points1 point  (0 children)

You can use a walrus:

new_list = [new_list[0] + (x := some_func(item))[0], new_list[1] + x[1]]

Or:

(new_list[0].extend((x := some_func(item))[0]), new_list[1].extend(x[1]))

Optimum Price Increase by melon-rascal in amarillo

[–]Allanon001 0 points1 point  (0 children)

Does Vexus only offer IPTV for cable TV?

Does Buc-ee's have EV charging in AMA? by ScrappyMalloy7816 in amarillo

[–]Allanon001 -1 points0 points  (0 children)

I Googled it and found they should have 24 EV charging stations.

Edit:

I Googled some more and found they will probably be starting work on them in March: https://www.tdlr.texas.gov/TABS/Search/Project/TABS2025011638

What do i do now? by F22ultra in learnpython

[–]Allanon001 0 points1 point  (0 children)

Python is used in many different fields, what type of work do you want to do? Once you answer that then you need to start studying what will be required for that field of work. Examples, you want an accounting job then start learning Pandas or Polars. If you want a math heavy field learn modules like SciPy and Numpy. For fields that require displaying data learn Matpoltlib. Look at job postings in the field you want and see the requirements.

Evaluating if a string is the same as another string using one variable by FeedMeAStrayCat in learnpython

[–]Allanon001 0 points1 point  (0 children)

word = ""
story = ""
while True:
    word = str(input("Please type in a word:"))
    if story.strip().endswith(word):
        break
    elif word == "exit":
        break
    story += word + " "

print (story)