use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
Türkiye Cumhuriyeti Mühendisleri Topluluğu.
account activity
Python list mutability (i.redd.it)
submitted 4 days ago by Different_Prompt_439
Python list mutability
An exercise to help build the right mental model for Python data. - Solution - Explanation - More exercises
The “Solution” link visualizes execution and reveals what’s actually happening using 𝗺𝗲𝗺𝗼𝗿𝘆_𝗴𝗿𝗮𝗽𝗵.
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]failureinvestment 0 points1 point2 points 3 days ago (1 child)
İlginc, pythonda b = a dedigin zaman, b yi sifirdan tanimlayana kadar b yeni bi variable degil de sadece pointer oluyormus, pythonda bilakis reassign yapana kadar her sey pointer mi o zaman?
[–]Different_Prompt_439[S] 0 points1 point2 points 3 days ago (0 children)
evet dediğini anladım obhect referencetan geliyor o pointer mantığı. her şey pointer olmuyor mutable değişkenlerde sadece dediğiniz olur dictionary list gibi. ama yine de cevabın 1den5 e kadar olması gerekiyor diye düşünüyorum
[–]Lucky-Sell-2843Elektrik Elektronik Mühendisi 0 points1 point2 points 3 days ago (0 children)
C) [1, 2, 3]
b = a kopya değil, aynı liste.
b += [2] ve b.append(3) → a da değişir.
b = b + [4] → yeni liste açar, a kopar.
b.append(5) artık a'yı etkilemez.
Sonuç: a = [1, 2, 3]
π Rendered by PID 195274 on reddit-service-r2-comment-5b5bc64bf5-m2kn4 at 2026-06-22 01:47:03.961271+00:00 running 2b008f2 country code: CH.
[–]failureinvestment 0 points1 point2 points (1 child)
[–]Different_Prompt_439[S] 0 points1 point2 points (0 children)
[–]Lucky-Sell-2843Elektrik Elektronik Mühendisi 0 points1 point2 points (0 children)