I've just started learning hadoop and following "Hadoop - The Definitive Guide".

I tested the first way to write Map and Reduce classes where the Mapper and Reducer were interfaces. The code just worked fine.
Then I started writing code where the Map and Reduce are abstract classes with Context class.
BTW, I am using hadoop 1.2.1
 I see the below errors

```
MaxTemperatureReducer.java:5: error: cannot find symbol
public class MaxTemperatureReducer extends Reducer<Text, IntWritable, Text, IntWritable> 
                                       ^
  symbol: class Reducer
MaxTemperatureReducer.java:7: error: cannot find symbol
    public void reduce(Text key, Iterable<IntWritable> values, Context context) throws IOException,InterruptedException 
                                                           ^
  symbol:   class Context
  location: class MaxTemperatureReducer
MaxTemperature.java:5: error: cannot find symbol
import org.apache.hadoop.mapreduce.FileInputFormat;
                              ^
  symbol:   class FileInputFormat
  location: package org.apache.hadoop.mapreduce
MaxTemperature.java:6: error: cannot find symbol
import org.apache.hadoop.mapreduce.FileOutputFormat;
                              ^
  symbol:   class FileOutputFormat
  location: package org.apache.hadoop.mapreduce
MaxTemperature.java:7: error: cannot find symbol
import org.apache.hadoop.mapreduce.JobClient;

```

My Mapper class looks like

```
import java.io.IOException;
import org.apache.hadoop.io.IntWritable;
import org.apache.hadoop.io.LongWritable;
import org.apache.hadoop.io.Text;
//import org.apache.hadoop.mapreduce.MapReduceBase;
import org.apache.hadoop.mapreduce.Mapper;
public class MaxTemperatureMapper extends Mapper<LongWritable, Text, Text, IntWritable>
{
    private static final int MISSING = 9999;
    public void map(LongWritable key, Text value, Context context) throws IOException, InterruptedException
    {
    String line = value.toString();
    String year = line.substring(0, 4);
    int airTemperature;
    if (line.charAt(4) == '+')
    {
        airTemperature = Integer.parseInt(line.substring(5, 10));
    }
    else
    {
        System.out.println( line );
        airTemperature = Integer.parseInt(line.substring(4, 9));
    }
    System.out.println( "Mapper: " + year + ", " + airTemperature );
    context.write(new Text(year), new IntWritable(airTemperature));
    }
}

```

Can someone help?