i feel so stupid

posted in Off Topic
View:
Threaded
Linear
Threaded
#1
Foxym
0
Frags
+
–

i was looking for this:
https://i.ibb.co/fdxrtZKZ/image-1775421054014.png
in a big list (which ones was a webpage), to remove redundant data.
it ended up removing the data i needed and it made me go insane to say the least

after a while (2h) i found the issue

        indexidk = eweb.index("vm-stats-game-mod-active")
        print(indexidk)
        wiped = 0
        while wiped != indexidk:
            eweb.pop(wiped)
            wiped += 1

i kept incresing the index of what to wipe... it included the needed data by coincidence...
i now feel so stupid as the change was to just:

        indexidk = eweb.index("vm-stats-game-mod-active")
        print(indexidk)
        wiped = 0
        while wiped != indexidk:
            eweb.pop(0)
            wiped += 1

change the pop/removal_index to 0...
i feel so dumb

it took me 2 HOURS to find that out

#2
sh1lll
1
Frags
+
–

@MIT hire this guy

#4
Foxym
0
Frags
+
–

i think i should go to TUM instead of travelling half the globe

#5
Xool_233
0
Frags
+
–

@MIT give him a scholarship as well

#3
Galactc
0
Frags
+
–

It took me 2 months to fix a spelling issue for my computer science work
It can get so much dumber 😭

#6
forklift2
0
Frags
+
–

damn ur stupid

#7
mondely
0
Frags
+
–

if i am understanding this right, u are just popping the list until u get to the item u want. u forgot that by popping, the indexes for every item changes, so u ended up not wiping index 0 because wiped incremented above 0 after the first loop

#8
Foxym
0
Frags
+
–

basically, i know its slow but as of rn i dont know any quicker way

#9
mondely
0
Frags
+
–

I don't get something. if all you want is the item in eweb.index. why can't u just assign it to a new object/array(idk which one u using). Why go to all the trouble of popping the redundant data one by one for eweb

#10
Foxym
0
Frags
+
–

difficult to explain, im still a beginner and this is all self taught
i cant really explain
would post the entire subsection if i weren't in the middle of editing it

#11
mondely
0
Frags
+
–

aight goodluck

  • Preview
  • Edit
› check that that your post follows the forum rules and guidelines or get formatting help
Sign up or log in to post a comment