How do good students in medical school distinguish themselves?
Gone are the days when course marks are the only metric against which medical students are assessed. This is one of the reasons for the institution of pass/fail modules of instruction. This issue is difficult for medical students to understand, given that entry into medical school is contingent on tough criteria involving grade-based metrics. All these questions you've asked are tied to this old way of thinking.


  how do good students distinguish themselves?


Medical students distinguish themselves in ways other than course marks. They show compassion towards patients. They show creativity in their approach to problem solving. They demonstrate the ability to communicate effectively. They work well with their peers. They lead and follow, as is appropriate to achieve the best outcome for the patient.

It's not all about the marks. It's all about the patient.


  same question in terms of getting into top specialties as indication of how good of a student someone is


I believe that you're looking at the question ass backwards. In logic terms, your applying the fallacy called confirming the consequent.

Competitive people get into dermatology.
Sally got into dermatology.
Therefore, Sally is competitive.

I suggest that you refrain from judging the "competitiveness" of a doctor on the basis of his or her specialty.

The choice of specialty has been long studied and the motivation to pursue a particular medical specialty is based on a number of factors, not the least of which is personal preference. I can think of no one in my professional life as a medical doctor -- professors, peers, students -- who've pursued a clinical specialty simply because it was the most competitive thing to get into.

The "competitive" label of some specialties is a function of supply of training posts against demand for the profession. There are relatively few positions available for dermatology compared to the need of the population. I promise you, if dermatology places were to triple overnight, the "competitive" label would be lost. The same is true at the other end. There are many places for family medicine, some not able to be filled. 


  So how can you tell how good a student is in medical school if there is no GPA and if getting into a specialty also don't indicate that?


There is no single metric. Rather, I suggest that you understand the mechanics against which you will be assessed. These will differ as you progress through your medical training. At each stage, the everyone resets to zero, any you start from scratch. There is no carry over of grades. Let me give you an example. In the program I head, we receive 400 applications for the 12 training places we possess. Once we select our trainees, everyone is treated the same. Effectively, the utility of your GPA, your medical school award for perfect attendance, your three letters of recommendation -- all of these have served their purpose and we chuck them out. We don't care whether you were top of your class or bottom of your class. You're now in our class and our rules apply. Do you know who has the hardest time figuring this out? Well, it's the people who are fixated about class and status.

Anyway, good luck to you.