Want this question answered?
If you just want a hint: One way to check whether a number is prime is by dividing it by any number between 2 and the square root of your number. If the number divides by any of these, it is not prime. If you want the code: import math for num in range(1,101): if all(num%i!=0 for i in range(2,int(math.sqrt(num))+1)): print num
i ll give you the logic and if u know a lil bit of c u can make it.. accept the two no's from user==> use scanf if the 1st no is 2 print that using printf like>>1st no is prime then put a nested for loop i.e. for (int i = 1st no ;i <=2nd no; i ++) { for (int j= 2 ; j <i; j++) now check for condition if i/j==0 then printf not prime else printf prime so its over u see.....
// one dimensional array 'num' of type int...int num[100];{Sorry, diagrams are not possible in wiki.answers.com, you have to use words}This is 100 copies of an integer data type, arranged sequentially in memory. The first one is called num[0], the tenth one is called num[9], and the 100th one is called num[99].// two dimensional array 'matrix' of type float...float matrix[10][20];This is 200 copies of a floating point data type, arranged sequentially in memory. The first one is called matrix[0][0], the tenth one is called matrix[9][0], the eleventh one is called matrix[0][1], and the 200th one is called matrix[9][19].In both cases, you don't want to "think" about the arrangement of bits and bytes within each int or float. Doing so is non-portable, and can lead to problems down the road. The only safe thing you can consider is the arrangement in memory of the copies of the fundamental type int or float.
In a pass by pointer (*, the original C standard), you're not passing the actual variable but rather its address in memory. This is required because in standard C, all function parameters are passed by value and therefore disappear when the function call is completed. In order to access and alter the original variable, you have to dereference the pointer using the address provided in the pointer argument, and this must be done each time the original variable is altered. Keeping this in mind requires vigilance to be sure you know which object referring: the variable or its memory address.In a pass by reference (&, introduced in C++), you're telling the compiler that the variable being passed into a function has to be fundamentally linked to the original. The compiler takes care of the dirty work and lets you refer to the variable with simple assignment statements--no pointer handling required.
#include <stdio.h> #include <conio.h> void main() { int num,rev=0,m,r; clrscr(); printf("enter any number"); scanf("%d",&num); m=num; while(num>0) { r=num%10; rev=rev*10+r; num=num/10; } if(rev==m) printf("given number is palindrome"); else printf("given number is not palindrome"); getch(); } this is the answer.
On the Harmonic balancer there are several marks on the right the marks start at 30* BTC (Before top dead center) Going left the marks stop at 0* (TDC) you need to line this up with a mark that is just to the right of the crankshaft position sensor. One you line up the 0* mark with the mark you will have TDC. NOTE: There are two TDC one is the power stroke and one is the compression stroke most specs require you to be on TDC compression
The intake valves line up with the intake runners on the intake manifold. The exhaust valves line up with the exhaust runners on the exhaust manifold or headers. With #1 at tdc you can set 1,2,5,7 intake and 1,3,4,8 exhaust valves. Rotate the engine one revolution to #6 tdc and set the remaining valves.
how do you set tdc on 2004 kia Rio
At TDC compression it points to the number one post on the cap.
5 degrees before TDC. There's a mark on the stator plate and one on the case, just line them up.
You must be at TDC on the Compression stroke.
TDC means Total Dead Center. To bring your car to a TDC correctly, you pull off the number one plug and stuff your finger into the hole.
The TDC is when the number one cylinder is at the top or top dead center of the compression.
If you are installing the timing chain on a 2.7L, the number one cylinder will not be at TDC. That is normal.If you are installing the timing chain on a 2.7L, the number one cylinder will not be at TDC. That is normal.
Num Nutts is the title for a guy who is persistant to being a glutten for punishment. For example, a Num Nutts guy might be one who is persistant in parking his car in a place where he keeps-on getting expensive parking tickets.
On the card
on the top right corner of your keyboard there are 3 led which glows on the 'ON' of few buttons like the first one is for num lock, second one is for caps lock and 3rd one is for scroll lock