473,382 Members | 1,622 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,382 software developers and data experts.

+= plus equal sign

What does += mean?
Expand|Select|Wrap|Line Numbers
  1. int julian_day( int month, int day, int year )
  2. {
  3.   int jday = 0;
  4.   for (int m=1; m<month; ++m )
  5.     { 
  6.       jday += DaysInMonth[m];
  7.       if ( m == 2 && is_leap_year(year))
  8.           ++jday;  // February 29th
  9.     }
  10.   jday += day;
  11.   return jday;
  12. }
Thanks a lot
Jul 28 '07 #1
2 70932
11,448 Expert 8TB
+= is the 'add assignment operator; e.g.

Expand|Select|Wrap|Line Numbers
  1. int foo= 1;
  3. foo+= 41; // foo has value 42 now
You can do the same with most of the other binary operators; && and || can't
be used like that.

kind regards,

Jul 28 '07 #2
eg a+=1 means a=a+1 such an operation can be used for all arithmetic operations
Jul 28 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

by: r0adh0g | last post by:
I am attempting to build a primitive search form on my site. It is searching an Access Database Table and comparing on field in the database to a field passed from the form. Works great if only...
by: johndesp | last post by:
I am building an xml document to represent a url request. Some urls contain d equal signs appended to the url. Its important I preserve the equal sign in hte xml document. However, my parser is...
by: lbbs | last post by:
Newbie, so please don't flame me. I am just starting to learn access. I seem a feature in access a while ago, but don't remember what it was called. I seen project lab example that had, a plus...
by: Emil Georgiev | last post by:
Hell I have a Web Custom Control project in ASP.NET. I'm using a subclassing technique to add functionality in HyperLink web server control. I want to create a property "BrowserWindow" of my...
by: buntyindia | last post by:
Hi , I am exporting files from my application. Files those are not supposed to be exported are of two types : 1.) Blank with Zero bytes 2.) Other one is in a format # #Mon Aug 13 14:33:02...
by: sesseth | last post by:
can someone help me, it says "Operator "=" is not defined for types "System.Drawing.Point" and "System.Drawing.Point"" The code is "Rabbitbox.Location = Carrots.Location" any ideas?
by: =?ISO-8859-1?Q?Konrad_M=FChler?= | last post by:
Hi, a simple question: Which standard function in c++ gives me the sign of a number? Thanks Konrad
by: souporpower | last post by:
Hi All I am using ajax as follows: var parameters = "groups=" + escape(myemail+100@gmail.com); var url="/mydomain/ajaxCall"; if (req != null) { req.open("POST", url, true);
by: =?Utf-8?B?Sm9zdWZm?= | last post by:
Hi: I've been using MSN Bill Pay for years to pay my bills. I recently decided to look into Microsoft Money as I wanted a desktop application to manage and pay my bills. I downloaded the...
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.