Check if two unordered lists are equal

Python has a built-in datatype for an unordered collection of (hashable) things, called a set. If you convert both lists to sets, the comparison will be unordered. Documentation on set EDIT: @mdwhatcott points out that you want to check for duplicates. set ignores these, so you need a similar data structure that also keeps track of the number of … Read more

Python – how to use the constant e^

The function you’re using is known as the sigmoid function. You can build a function that will calculate every sigmoid of x. In order to use e^(x) you can use the numpy function exp as shown in the example.