1
$\begingroup$

I want to assign Subscript[C,i] by mapping a specific list. For example, the list is {1,2,3,4}, and I want to assign 1 to C1, 2 to C2, 3 to C3 and 4 to C4. How should I do? Many thanks:)

$\endgroup$

1 Answer 1

3
$\begingroup$

Just Map over the list, like:

(Subscript[c, #] = #) & /@ {1, 2, 3}
$\endgroup$
1
  • $\begingroup$ very help! thanks! $\endgroup$
    – Winnie Lee
    Feb 28, 2014 at 12:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.