my program is not working using "Serial.println()"

i was making a thermistor based digital thermometer. i connected 1k ohm and 100k ohm thermistor(NTC) in series.i supplied with 5v in board. i take voltage using analog pin A0 across the thermistor. i used the program in
example -> Basics -> ReadAnalogVoltage in arduino programmer(1.0.2) it was working fine.but i did few calculation to convert voltage to resistance and display in serialprint() it is not working.........
code i below please help me in debugging..........

void setup() {
// initialize serial communication at 9600 bits per second:
Serial.begin(9600);
}

// the loop routine runs over and over again forever:
void loop() {
// read the input on analog pin 0:
int sensorValue = analogRead(A0);
// Convert the analog reading (which goes from 0 - 1023) to a voltage (0 - 5V):
float voltage = sensorValue * (5.0 / 1023.0);
// print out the value you read:
float resistance=((5 - voltage)/(voltage * 1000));
Serial.println(resistance);
}

step by step? (If 1k near 5V)

 float voltage = sensorValue * (5.0 / 1023.0); // near 4.9V at room temp
  float current=(5.0-voltage)/1000; 
  float resistance=voltage/current; 
  Serial.println(resistance);

I would choose a series R >1k