657
edits
Line 27: | Line 27: | ||
<!-- {{SyntaxHighlight| --> | <!-- {{SyntaxHighlight| --> | ||
{{Code|Conversion of Python's dict to structure|<syntaxhighlight lang="octave" style="font-size:13px"> | {{Code|Conversion of Python's dict to structure|<syntaxhighlight lang="octave" style="font-size:13px"> | ||
x = pyeval ("{1:'one',2:'two'}"); | > x = pyeval ("{1:'one',2:'two'}"); | ||
x.("1") | > x.("1") | ||
ans = one | ans = one | ||
x.("2") | |||
> x.("2") | |||
ans = two | ans = two | ||
> x = pyeval ("{(1,1):'one',2.5:'two'}"); | |||
> x.("(1,1)") | |||
ans = one | |||
> x.("2.5") | |||
ans = two | |||
</syntaxhighlight>}} | </syntaxhighlight>}} | ||
edits