ICP 2 - manaswinivedula/Big-Data-Programming GitHub Wiki

Task1:: To run a word count program on sample text file using Hadoop Mapping and reducing functions.

Initially, I have created a new Java project in Eclipse and then imported the external jar files from the Hadoop library and client. Then exported this code into a jar file and ran the below command.

This is the code of the Word count task

This is the output file of Word count in the Hue.

Task2:: To count the words starting with the alphabet "a" using Hadoop Mapping and reducing functions.

The Reducer code for Task 2 is shown below.

The following is the output of Task 2

Task3:: To check whether the given number is prime or not using Hadoop Mapping and reducing functions. where 0 represents prime number 1 represents a nonprime number.

The following is the reducer code for Task3.

The following is the output of Task3.

Links:

Video

Refernces