#StackBounty: #learning #memory #long-term-memory #language-processing #aging Does language learning improve or worsen the ability to r…

Bounty: 100

In an interview with a Czech neurologist Syka, I’ve heard that much of the mental health (such as the ability to reason, communicate and process information) in older age mainly depends​ on the amount of informational ballast we create. The argument states that with this additional information, we unnecessarily wear some of the basic mental mechanisms out (Even though there’s no the effect of “too much memories”). Does knowledge of more languages tend to improve or worsen these mental skills?


Get this bounty!!!

Sort a list of tuples by Nth item in Python

Suppose you have a list of tuples that looks something like this:

[('abc', 121),('abc', 231),('abc', 148), ('abc',221)]

And you want to sort this list in ascending order by the integer value inside the tuples.

We can achieve this using the key keyword with sorted().

sorted([('abc', 121),('abc', 231),('abc', 148), ('abc',221)], key=lambda x: x[1])

key should be a function that identifies how to retrieve the comparable element from your data structure. For example, the second element of the tuple, so we access [1].

Source: StackOverflow.com