Sep 4, 2013 #1 M me0414013 Junior Member level 3 Joined Aug 30, 2012 Messages 28 Helped 0 Reputation 0 Reaction score 0 Trophy points 1,281 Location ongole Activity points 1,504 if a>b it assigns a to c,if not it assigns to b. is that all. is it same as "assign c=(a>b)? a:b;" can u please suggest a good book on verilog? Last edited: Sep 4, 2013
if a>b it assigns a to c,if not it assigns to b. is that all. is it same as "assign c=(a>b)? a:b;" can u please suggest a good book on verilog?
Sep 4, 2013 #2 M Mohammed_Verification Full Member level 2 Joined Sep 3, 2013 Messages 122 Helped 12 Reputation 24 Reaction score 12 Trophy points 18 Location India Activity points 602 Re: hi whats the meaning of the statement "assign c=(a>b);" in verilog???? me0414013 said: if a>b it assigns a to c,if not it assigns to b. is that all. can u please suggest a good book on verilog? Click to expand... Hi friend ,[assign c=(a>b)]; and assign c= (a>b)?a:b; are different assign c= (a>b)?a:b; if a greater than b then c=a; if a less than b then c=b; and here [assign c=(a>b)]; it works like a true or false condition checking if a greater than b then c=1; if a less than b then c=0; Hope this may be helpful to you... Rest of the friends correct me if i am wrong... Last edited: Sep 4, 2013
Re: hi whats the meaning of the statement "assign c=(a>b);" in verilog???? me0414013 said: if a>b it assigns a to c,if not it assigns to b. is that all. can u please suggest a good book on verilog? Click to expand... Hi friend ,[assign c=(a>b)]; and assign c= (a>b)?a:b; are different assign c= (a>b)?a:b; if a greater than b then c=a; if a less than b then c=b; and here [assign c=(a>b)]; it works like a true or false condition checking if a greater than b then c=1; if a less than b then c=0; Hope this may be helpful to you... Rest of the friends correct me if i am wrong...
Sep 4, 2013 #3 M me0414013 Junior Member level 3 Joined Aug 30, 2012 Messages 28 Helped 0 Reputation 0 Reaction score 0 Trophy points 1,281 Location ongole Activity points 1,504 Re: hi whats the meaning of the statement "assign c=(a>b);" in verilog???? Mohammed Ibrahim said: Hi friend ,[assign c=(a>b)]; and assign c= (a>b)?a:b; are different assign c= (a>b)?a:b; if a greater than b then c=a; if a less than b then c=b; and here [assign c=(a>b)]; it works like a true or false condition checking if a greater than b then c=1; if a less than b then c=0; Hope this may be helpful to you... Rest of the friends correct me if i am wrong... Click to expand... thanks a lot
Re: hi whats the meaning of the statement "assign c=(a>b);" in verilog???? Mohammed Ibrahim said: Hi friend ,[assign c=(a>b)]; and assign c= (a>b)?a:b; are different assign c= (a>b)?a:b; if a greater than b then c=a; if a less than b then c=b; and here [assign c=(a>b)]; it works like a true or false condition checking if a greater than b then c=1; if a less than b then c=0; Hope this may be helpful to you... Rest of the friends correct me if i am wrong... Click to expand... thanks a lot