Answer:
brainliest plsss
Explanation:
I think so this is what you had asked!!!!!!
hope it helps
Answer:
Explanation:
The following code is written in Java. Both functions traverse the linkedlist, until it reaches the desired index and either returns that value or deletes it. If no value is found the function terminates.
public int GetNth(int index)
{
Node current = head;
int count = 0;
while (current != null)
{
if (count == index)
return current.data;
count++;
current = current.next;
}
assert (false);
return 0;
}
public int removeNth(int index)
{
Node current = head;
int count = 0;
while (current != null)
{
if (count == index)
return current.remove;
count++;
current = current.next;
}
assert (false);
return 0;
}
Answer:
a peripheral device is a device used to put information into as well as get information out of a computer
Explanation:
Answer:
A Palmtop or hand-held personal computer is small enough to hold in one hand and operate with the other. Also called a handtop, these ultra-small computers may have specialized keyboards or keypads for data entry applications or have small qwerty keyboards.
• Palmtops are also called PDAs, hand-held computers and pocket computers.
• Palmtop or hand-held personal computer, lightweight, small, battery-powered, general-purpose programmable computer. It typically has a miniaturized full-function, typewriter like keyboard for input and a small, full color, liquid-crystal display for output. In addition to an operating system that is compatible with that of a desktop computer, a palmtop will typically contain a word processor, a spreadsheet program, and a calendar and phone book. A variety of other programs can be loaded and executed, and data can usually be transferred to and from a desktop computer. Although some palmtops are like personal digital assistants in that they accept handwritten or touch screen input, they generally differ in that the palmtop has more memory, a keyboard, and a greater variety of available programs.
Explanation:
Answer:
The prototype part missing has been assumed to be:
int reverseNum (int num);
Code:
#include <iostream>
using namespace std;
int reverseNum(int num);
int main()
{
int num=0,result=0;
cout<<"Enter the number:";
cin>>num;
result=reverseNum(num);
cout<<"The reversed number :"<<result<<endl;
return 0;
}
int reverseNum(int num)
{
int temp=0,digit=0;
for(num;num>0;num=num/10)
{
digit=num%10;
temp=temp*10+digit;
}
return temp;
}
Explanation: