Understanding and coding Neural Networks From Scratch in Python and R