At Westonci.ca, we connect you with the best answers from a community of experienced and knowledgeable individuals. Our Q&A platform provides quick and trustworthy answers to your questions from experienced professionals in different areas of expertise. Get detailed and accurate answers to your questions from a dedicated community of experts on our Q&A platform.

In the Small Basic programming language, please explain how one would add up the sum of any
number of data points. Meaning, that, depending on user input (the amount of data points there are) and the data (the entered data for each data point) I can calculate the sum, regardless of how many there are. Is there a way to do this?


Sagot :

acid
Simply put both values as variables. It's been a long time since I used small basic, as it was only used as an introductory language (I use Python, now)

userInputVariable  +  dataPointVariable

A key point to remember for the written theory exam is when the variables are strings, this process is called concatenation.