Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / NewStats: 3,200,110 members, 7,973,735 topics. Date: Sunday, 13 October 2024 at 03:35 AM |
Nairaland Forum / Science/Technology / Programming / Lets Solve Some Javascript Problems (914 Views)
Check In: Submit Your C++ Questions Lets Solve / Lets Solve Some Javascript Problems / Javascript Problems (2) (3) (4)
(1) (Reply)
Lets Solve Some Javascript Problems by elvongray: 4:58pm On Dec 12, 2014 |
A vector type Write a constructor Vector that represents a vector in two-dimensional space. It takes x and y parameters (numbers), which it should save to properties of the same name. Give the Vector prototype two methods, plus and minus, that take another vector as a parameter and return a new vector that has the sum or difference of the two vectors’ (the one in this and the parameter) x and y values. Add a getter property length to the prototype that computes the length of the vector—that is, the distance of the point (x, y) from the origin (0, 0) |
Re: Lets Solve Some Javascript Problems by abdul01(m): 11:02pm On Dec 12, 2014 |
Please pardon me, i know say i try sha
|
(1) (Reply)
Android App Database / 5 Truths And Myths About Magento Ecommerce Platform / Govt Should Help Developers Especially Beginners
(Go Up)
Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health religion celebs tv-movies music-radio literature webmasters programming techmarket Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10) Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 7 |