First Folio:   The First Folio (Mr. William Shakespeares Comedies Histories, & Tragedies. Published according to the True Originall Copies), published in 1623, was the first collected edition of Shakespeare's plays. The Ramparts Scene in Hamlet appears on pages 156, 257, 258, and 259 of the "Tragedies" section of the book.
Folger Shakespeare Library
First Quarto:   Published in 1603, the Hamlet First Quarto has the shortest text of the three versions of Hamlet. It is considered by many as one of the "Bad" Quartos, possibly transcribed from memory by actors. Two copies of the Hamlet First Quarto exist.
Huntington Library
Second Quarto:   Published in 1604/5, the Hamlet Second Quarto is the longest text of the three versions of Hamlet by approximately 200 lines. Seven copies of the Hamlet Second Quarto exist.
Folger Shakespeare Library   Huntington Library
Third Quarto:   The Third Quarto of Hamlet was published in 1611 by John Smethwick, to whom Nicholas Ling (the "N.L." of the Second Quarto title page) had transferred his rights. The Second Quarto served as copy for the Third, which in turn served as copy for the Fourth Quarto, published before 1623. Images courtesy of Schoenberg Center for Electronic Text & Image, University of Pennsylvania.
Furness Shakespeare Library, University of Pennsylvania