first commit

main function(decoding, learning key) has been tested, but i can ensure
it work perfectly!