how to get a latitude and longitude ?

Simple TinyGPS library v. 13
by Mikal Hart

CHARS=419 SENTENCES=0 CSUM ERR=0
CHARS=872 SENTENCES=0 CSUM ERR=0
CHARS=1291 SENTENCES=0 CSUM ERR=0
CHARS=1694 SENTENCES=0 CSUM ERR=0
CHARS=2097 SENTENCES=0 CSUM ERR=0
CHARS=2458 SENTENCES=0 CSUM ERR=0
CHARS=2819 SENTENCES=0 CSUM ERR=0
CHARS=3180 SENTENCES=0 CSUM ERR=0
CHARS=3549 SENTENCES=0 CSUM ERR=0

why i did not get a latituude and longitude at the serial monitor??
this is a code for gps(neo6mv2)

#include <SoftwareSerial.h>

#include <TinyGPS.h>

/* This sample code demonstrates the normal use of a TinyGPS object.
It requires the use of SoftwareSerial, and assumes that you have a
4800-baud serial GPS device hooked up on pins 4(rx) and 3(tx).
*/

TinyGPS gps;
SoftwareSerial ss(4,3);

void setup()
{
Serial.begin(9600);
ss.begin(9600);

Serial.print("Simple TinyGPS library v. "); Serial.println(TinyGPS::library_version());
Serial.println(“by Mikal Hart”);
Serial.println();
}

void loop()
{
bool newData = false;
unsigned long chars;
unsigned short sentences, failed;

// For one second we parse GPS data and report some key values
for (unsigned long start = millis(); millis() - start < 1000;)
{
while (ss.available())
{
char c = ss.read();
// Serial.write(c); // uncomment this line if you want to see the GPS data flowing
if (gps.encode(c)) // Did a new valid sentence come in?
newData = true;
}
}

if (newData)
{
float flat, flon;
unsigned long age;
gps.f_get_position(&flat, &flon, &age);
Serial.print(“LAT=”);
Serial.print(flat == TinyGPS::GPS_INVALID_F_ANGLE ? 0.0 : flat, 6);
Serial.print(" LON=");
Serial.print(flon == TinyGPS::GPS_INVALID_F_ANGLE ? 0.0 : flon, 6);
Serial.print(" SAT=");
Serial.print(gps.satellites() == TinyGPS::GPS_INVALID_SATELLITES ? 0 : gps.satellites());
Serial.print(" PREC=");
Serial.print(gps.hdop() == TinyGPS::GPS_INVALID_HDOP ? 0 : gps.hdop());
}

gps.stats(&chars, &sentences, &failed);
Serial.print(" CHARS=");
Serial.print(chars);
Serial.print(" SENTENCES=");
Serial.print(sentences);
Serial.print(" CSUM ERR=");
Serial.println(failed);
if (chars == 0)
Serial.println("** No characters received from GPS: check wiring **");
}

Just print the raw data from the GPS to the screen. You should see the NMEA sentences. If not, there's a problem like the wrong baud rate or you plugged an RS232 device in without an RS232 converter.

Always use code tags when posting ("</>" button).

Uncomment this line to see the raw data:

     // Serial.write(c); // uncomment this line if you want to see the GPS data flowing

why i did not get a latituude and longitude at the serial monitor??

You do have the GPS outside don't you ?

They dont usually work indoors.

CHARS=3549 SENTENCES=0 CSUM ERR=0

The 'SENTENCES=0' part means that it hasn't received a valid fix from the satellites. In addition to what srnet has said about not working indoors you don't seem to be leaving it long to get a fix in any case. It can be a matter of minutes before it returns valid data.