help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Structures


From: Mike B.
Subject: Structures
Date: Wed, 10 Feb 2010 19:48:06 -0800 (PST)

Hi All,

Would appreciate advice how to the following efficiently:
I have two structures A and B.
1. Need to cycle over the fields of A in a particular order.
2. If B has a field with an identical name then A is assigned the content of 
B's field.
3. Evaluate the field in A.

For example (f1 then f2 then f3):
A.f1 = 1    
A.f2 = A.f1 * 2
A.f3 = "abc"

B.f2 = A.f1 *5
B.f3 = "def"

so after looping over A (and given B) the output is
A.f1 = 1
A.f2 = 5
A.f3 = "def"


Cheers,
Mike.


      New Email names for you! 
Get the Email name you've always wanted on the new @ymail and @rocketmail. 
Hurry before someone else does!
http://mail.promotions.yahoo.com/newdomains/aa/



reply via email to

[Prev in Thread] Current Thread [Next in Thread]