Monday, December 30, 2019

Inner and Outer - Hacker Rank Solution

Inner and Outer - Hacker Rank Solution

We can solve this using the inner and outer tools.

import numpy

A = numpy.array(map(int, raw_input().split()))
B = numpy.array(map(int, raw_input().split()))

print numpy.inner(A, B)
print numpy.outer(A, B) 

No comments:

Post a Comment

Powered by Blogger.