How can i represent python dictionary in real math? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 2

How can i represent python dictionary in real math?

For example {'x': 10, 'y': 20,' z': 30} - in what structure it can be converted?

1st Feb 2017, 9:30 AM
Oleg Chulanovskyi
Oleg Chulanovskyi - avatar
6 Answers
+ 3
When I said matrix, I was meaning a unique row matrix... as your dict in example let be thinking to a 3D triplet coordinates, which can be handle as list, so multi rows matrix ;) Anyway, it's an conceptual abstract structure for human handle help in programming: you probably cannot just transpose it in "real math"...
1st Feb 2017, 10:12 AM
visph
visph - avatar
+ 3
There's no weird question: iit's weird to not ask if we don't know and want to ;)
1st Feb 2017, 11:49 AM
visph
visph - avatar
+ 2
Maybe a function, defined value-wise: f('x') = 10, f('y')=20, f('z')=30.
1st Feb 2017, 11:27 AM
Álvaro
+ 2
Vector? Set? Equation system?
27th Apr 2017, 6:17 PM
Andrew Harchenko (Tomsk)
Andrew Harchenko (Tomsk) - avatar
+ 1
A matrix with named parameters? Think at it just as an array indexed by names instead by integers values... It's more useful to handle explicits references names to access to a structure of array like a triplet of 3D coordinates by their names than by an index ( 0 for x, 1 for y, 2 for z: ok, but less readable, more source of mistakes ) ^^
1st Feb 2017, 9:52 AM
visph
visph - avatar
+ 1
Maybe this question is weird, but i've been asked for this question on interview))
1st Feb 2017, 11:46 AM
Oleg Chulanovskyi
Oleg Chulanovskyi - avatar