RemoveMember
Removes a member from a structure.
Syntax
-
RemoveMember(S, s)
-
S
is a structure -
s
is a string
-
-
RemoveMember(S, i)
-
S
is a structure -
i
is an integer
-
Description
If S
is a structure and s
the name of one of the members of S
, then RemoveMember(S, s)
returns S
with the member named s
removed.
If S
is a structure and i
a valid index for a member of S
, then RemoveMember(S, i)
returns S
with the member with index i
removed.
Examples
struct("a": 3, "b": 10)
a: 3 b: 10
RemoveMember(ans, "a")
b: 10