Answer:
There are two ways to print 1 to 1000
- Using Loops.
- Using Recursion.
Explanation:
Using loops
for(int i=1;i<=1000;i++)
{
cout<<i<<" ";
}
Using recursion
Remember you can implement recursion using a function only.
void print(int n)
{
if(n==0)
return;
print(n-1);
cout<<n<<" "';
}
you should pass 1000 as an argument to the function print.
Indents? Double Space? one of those
If you're doing an interview via phone I wouldn't suppose you would need to get dressed into anything specific. If it's going to be a video call, then you should at least wear something presentable that the camera will see (that means you don't have to wear pants).
Sorry, if you're looking for some specific answer then I can't help you. This question just kinda throws common sense out there and it's just your job to use it.
Answer:
Tags can be identified as they are written as <tagname> Something </tagname>
<tagname> this tag is called start tag.
</tagname> this tag is called as end tag.
for ex:<p> This is a paragraph </p>
There are some elements with no end tag.for ex:- <br> tag.
Attributes are used to provide additional information to an HTML element.
Every element can have attributes.
for Ex:- <h1 style="background-color:red";>MY WEBSITE </h1>
So the background of h1 will become red.