1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
klasskru [66]
3 years ago
5

. Write a swift programming code to perform following tasks a) Declare a variable that stores the age of a person b) Declare a c

onstant that stores the earth gravity 9.8
Computers and Technology
1 answer:
Law Incorporation [45]3 years ago
5 0

Answer:

Here we use the shift programming  code

(a)var age1: Int=24

(b)let ear_grav:Float=9.8

Explanation:

(a) To declared any variable in swift we follow following syntax

Syntax:var variableName = <initial value>

var age1: Int=24

Here age1 is a variable that stores the age of a person

to print this use we print command in swift

print(age1)

(b)To declared the constant in swift we follow following syntax

Syntax: let constantName = <initial value>

let ear_grav:Float=9.8

Here ear_grav is a constant that stores the earth gravity 9.8

to print this use we print command in swift

print(ear_grav)

You might be interested in
your computer running Windows 10 is doing some very strange things with operating system you are fairly certain it is not a hard
AlekseyPX
It might be a virus, when my computer starts going crazy i just bought a fixme stick and they work amazing or trying getting an expert to fix it if it worse
6 0
2 years ago
Read 2 more answers
Mary is writing an article about the animal kingdom. She wants to place an image below the text. Which menu should Mary choose f
diamong [38]

Answer:

Idk

Explanation:

Idk

8 0
3 years ago
. What process skill would a scientist use to find the length of a line
Brilliant_brown [7]

Answer:

Explanation:

A ruler

;););););););););););););););)

7 0
3 years ago
What symbol precedes all structured references in formula autocomplete lists?
Zolol [24]
Structured references make it easier to use formulas with Excel tables by ... Use brackets around specifiers All table, column, and special item ...
4 0
2 years ago
why is it useful to learn how to solve and program solutions with a limited set of command in computer science
12345 [234]

Answer:

Give at least one reason why it's useful to learn how to solve and program solutions with a limited set of commands. So that when there is more commands we know how to use the ones we have. parameters help generalize the solution to a specific problem. how are functions with parameters an example of abstraction?

4 0
2 years ago
Other questions:
  • The sum of all the minterms of a boolean function of n variables is equal to 1.
    7·1 answer
  • The set of appearance choices for files and folders is known as the
    7·1 answer
  • You are in charge of designing a menu tree for navigating 1,250 books in a digital library. Present an argument of whether the m
    12·1 answer
  • When we put 10+ points for when we ask a question, do we loose the points we have?
    12·1 answer
  • Which of the following is not an example of technological progress? A: new scientific knowledge that has practical applications
    12·2 answers
  • How can you ensure that your web pages are compliant with a w3c standard?
    9·1 answer
  • According to the "multiple-selves" theory, of an online DVD rental service could offer same-day deliveries, so that people who o
    9·1 answer
  • The design of a blog refers to:
    10·1 answer
  • Accenture has partnered with a global construction company that specializes in building skyscrapers. The company wants better ma
    12·1 answer
  • A while loop should be used if you want the user to watch the same video three times.
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!