MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi test

Learn moreOpportunities for recent engineering grads.

Apply Todayinner product of two vectors

952 correct solutions
1709 incorrect solutions

Last solution submitted on Jul 21, 2016

2 players like this problem

1 Comment

Jerivington
on 30 May 2016

eazy eazy

3 Comments

Daniel Pereira
on 16 Apr 2013

Why is this smaller than just x*y'?

Carlos Adrian Vargas Aguilera
on 1 Jul 2013

NOt just that, his output is y instead of z!! jajaj...

Mineralter
on 30 Sep 2013

That is the matrix attribute!

1 Comment

Harish Maradana
on 23 Nov 2012

i wrote solution like below
z = sum(x.*y);
it is working on my laptop but in cody show incorrect tell me why

3 Comments

Bryce
on 2 Feb 2012

Hmmm, description is a little confusing. Is length(x) always = length(y)? Are they nx1 or 1xn? Anyhow, I submitted several possible solutions (e.g. z = x'*y, z = sum(x.*y)) all of which failed the test suite ... but they work fine on my machine!

David Young
on 3 Feb 2012

Note that the output variable in the pattern is y, not z.

Stephen
on 1 Mar 2012

ha, yeah. thanks for commenting about that. I didn't see it either.

5 Comments