Skip to content

Scalar * Vector doesn't work #131

Closed
@Joe7M

Description

@Joe7M

I want to multiply a vector v by a scalar s. In the example below the result r is correct, but I can't access the components of r. Workaround is to do the multiplication component-wise.

dim r(2)
v = [5,0,0]
s = 2
r = s * v
print r
' -> output on the screen: [10,0,0]
print r(0)
' -> Error: Missing separator Or parenthesis

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions