Assignment Statements

Assignment Statements

Overview

An assignment statement in Deluge uses the assignment operator (=) to assign the result of an expression to a variable.
Syntax
  1. variable = expression;
 

Compound Assignment Operators

compound assignment operator is an operator that performs a calculation and an assignment at the same time. All Deluge binary arithmetic operators (that is, the ones that work on two operands) have equivalent compound assignment operators:


Examples
  1. The statement
  2. a += 10;
  3. is equivalent to
  4. a = a + 10;
Technically, an assignment is an expression, not a statement. Thus,a = 5 is an assignment expression, not an assignment statement. It becomes an assignment statement only when you add a semicolon to the end.

An assignment expression has a return value just as any other expression does; the return value is the value that’s assigned to the variable. For example, the return value of the expression a = 5 is 5. This allows you to create some interesting, but ill-advised, expressions by using assignment expressions in the middle of other expressions.

For example:
int a; int b; a = (b = 3) * 2; // a is 6, b is 3
Using assignment operators in the middle of an expression can make the expression harder to understand, so it’s not recommended.
 

    Zoho CRM Training Programs

    Learn how to use the best tools for sales force automation and better customer engagement from Zoho's implementation specialists.

    Zoho CRM Training
      Redefine the way you work
      with Zoho Workplace

        Zoho DataPrep Personalized Demo

        If you'd like a personalized walk-through of our data preparation tool, please request a demo and we'll be happy to show you how to get the best out of Zoho DataPrep.

        Zoho CRM Training

          Create, share, and deliver

          beautiful slides from anywhere.

          Get Started Now


            Zoho Sign now offers specialized one-on-one training for both administrators and developers.

            BOOK A SESSION








                                    You are currently viewing the help pages of Qntrl’s earlier version. Click here to view our latest version—Qntrl 3.0's help articles.




                                        Manage your brands on social media

                                          Zoho Desk Resources

                                          • Desk Community Learning Series


                                          • Digest


                                          • Functions


                                          • Meetups


                                          • Kbase


                                          • Resources


                                          • Glossary


                                          • Desk Marketplace


                                          • MVP Corner


                                          • Word of the Day


                                            Zoho Marketing Automation

                                              Zoho Sheet Resources

                                               

                                                  Zoho Forms Resources


                                                    Secure your business
                                                    communication with Zoho Mail


                                                    Mail on the move with
                                                    Zoho Mail mobile application

                                                      Stay on top of your schedule
                                                      at all times


                                                      Carry your calendar with you
                                                      Anytime, anywhere




                                                            Zoho Sign Resources

                                                              Sign, Paperless!

                                                              Sign and send business documents on the go!

                                                              Get Started Now




                                                                      Zoho TeamInbox Resources



                                                                              Zoho DataPrep Resources



                                                                                Zoho DataPrep Demo

                                                                                Get a personalized demo or POC

                                                                                REGISTER NOW


                                                                                  Design. Discuss. Deliver.

                                                                                  Create visually engaging stories with Zoho Show.

                                                                                  Get Started Now









                                                                                                      • Related Articles

                                                                                                      • Control Statements

                                                                                                        Overview A program consists of a number of statements which are usually executed in sequence. Programs can be much more powerful if we can control the order in which statements are run. To achieve this, deluge script offers developers the if,else ...
                                                                                                      • Conditional Statements

                                                                                                        This guide will help you with the following: 1. Overview 2. Syntax 3. Examples Overview Conditional statements examine specified criteria, and act in one way if the criteria are met, or in another way if the criteria are not met. The criteria is ...
                                                                                                      • Criteria in conditional statements

                                                                                                        This guide will help you with the following: Overview Syntax Example Applicable operators and expressions for TEXT expressions Applicable operators and expressions for NUMBER and Decimal expressions Applicable operators and expressions for DATE-TIME ...
                                                                                                      • Branching Statements

                                                                                                        Return Type: Return type is the data type specifier of the data returned by the function. If no data is returned by the function, the return type must be specified as void. Example 1: For AddRelatedList string getMySaasuData(string email) { ...
                                                                                                      • Debug Statements

                                                                                                        Description The info keyword is used in Validate, Success or Update actions to display debug messages to assist an app owner in debugging the application. The info message can be viewed only by the owner of the application by clicking on the ...
                                                                                                        Wherever you are is as good as
                                                                                                        your workplace

                                                                                                          Resources

                                                                                                          Videos

                                                                                                          Watch comprehensive videos on features and other important topics that will help you master Zoho CRM.



                                                                                                          eBooks

                                                                                                          Download free eBooks and access a range of topics to get deeper insight on successfully using Zoho CRM.



                                                                                                          Webinars

                                                                                                          Sign up for our webinars and learn the Zoho CRM basics, from customization to sales force automation and more.



                                                                                                          CRM Tips

                                                                                                          Make the most of Zoho CRM with these useful tips.



                                                                                                            Zoho Show Resources