“The purpose of morality is to teach you, not to suffer and die, but to enjoy yourself and live.” — Galt’s Speech, in Ayn Rand’s Atlas Shrugged
Morality is a code of values that an individual must choose to follow to live one’s life in reality. 
Morality is a set of universal, rationally discovered and objectively validated principles that one must apply to the particular concretes of one’s everyday life if one wishes to continue living in reality.
[Top Quote] Ayn Rand, For The New Intellectual 113
 Ayn Rand, Virtue of Selfishness 13
“Just as man cannot survive by any random means, but must discover and practice the principles which his survival requires, so man’s self-interest cannot be determined by blind desires or random whims, but must be discovered and achieved by the guidance of rational principles.” — Ayn Rand
Individuals need a moral code as knowledge for human beings on how to survive, unlike the other animals, is not automatic.
Unlike other organisms — bacteria, elephants or apes which act by instinct — humans beings have no automatic knowledge and must discover the principles needed to survive.
Every human being follows some kind of moral code — whether they are fully conscious of it or not — the choice is whether it is irrational or rational, logically consistent or contradictory, based on life in some imaginary existence or on life on earth. This choice will determine the course of their life and their happiness on earth.
Morality is the “science of self-preservation” and human fulfillment, or in the words of John Galt, a hero in Ayn Rand’s revolutionary novel Atlas Shrugged: “The purpose of morality is to teach you, not to suffer and die, but to enjoy yourself and live.” 
 Ayn Rand, For The New Intellectual 113
“Material objects as such have neither value nor disvalue; they acquire value-significance only in regard to a living being — particularly, in regard to serving or hindering man’s goals.” — Ayn Rand
A value is that for which one acts to gain and keep to sustain one’s life.
Examples of values include: food, air and drink to sustain you; clothing, an umbrella or shelter to protect you; a lecture to give you knowledge; a novel to to show you life as it could be and should be; a computer to make you more productive; a flight on an airplane to travel across the world, or a rocket to take you to the moon; a talk with a friend to discus a problem; a concert with your favorite musician; a movie to entertain you; pursuing the joy of raising a child into an adult; a partner to spend your remaining life with.
 Ayn Rand “From the Horse’s Mouth” Philosophy: Who Needs It 79
“Life or death is man’s only fundamental alternative. To live is his basic act of choice. If he chooses to live, a rational ethics will tell him what principles of action are required to implement his choice. If he does not choose to live, nature will take its course.” — Ayn Rand
The highest value (which determines the hierarchy of one’s other values) is one’s own life.
This is because the fundamental alternative a human being faces is existence or non-existence: life or death.
If one wishes to live, one must choose to take those actions to obtain the values necessary to sustain one’s existence. Without life, all other values are illusory. It is the fact that one is alive, that makes the need for values possible.
[Top quote] Ayn Rand “Causality Versus Duty” Philosophy: Who Needs It 99
“The moral purpose of a man’s life is the achievement of his own happiness.” — Ayn Rand *
To hold one’s life as the highest value is to be egoistic (that is self-interested, and self-ish).
Self-interest (egoism) means to hold one’s life as the ultimate standard of value (the measure by which one determines and judges one’s actions), regarding oneself as the primary beneficiary of one’s actions.
However, egoism is not an out-of-context concept but to be valid (i.e., truly egoistic and not self-destructive) egoism must be guided not by whims or unanalyzed emotions, but by reason.
Self-interest indicates the end (the self) of one’s actions; rational indicates the means (reason) of obtaining that end.
What objectively bridges the two is a rational code of moral principles that serve as one’s guide to action.
Rational self-interest means choosing to take those actions required by a human being, according to a reality-based, objectively validated moral code of values, so that one may live a flourishing life on earth.
In regards to one’s relationship with others, rational self-interest does not mean sacrificing oneself for others (what philosopher Auguste Comte coined as altruism or “otherism”) or sacrificing others for oneself (what is smeared as “selfishness”). Instead, rational self-interest means having a benevolent view of existence, seeing other individuals as traders with a shared harmony of interests, exchanging value for value — in the material (wealth and pleasure), intellectual (knowledge and discussion) and spiritual (love and friendship) realms.
*Ayn Rand “The Ethics of Emergencies” The Virtue of Selfishness 49
Virtue(s) are the actions necessary to sustain one’s life and achieve happiness; i.e., one’s method of obtaining values.
The fundamental virtue is rationality as reason is an individual’s means of survival. All other virtues (productivity, integrity, etc.) are applications/corollaries of this fundamental principle.
“It is only a living organism that faces a constant alternative: the issue of life or death. Life is a process of self-sustaining and self-generated action. If an organism fails in that action, it dies; its chemical elements remain, but its life goes out of existence. It is only the concept of ‘Life’ that makes the concept of ‘Value’ possible. It is only to a living entity that things can be good or evil.” — Ayn Rand
The good is that which sustains one’s life.
 Ayn Rand “The Objectivist Ethics” The Virtue of Selfishness 15
The evil is that which destroys one’s life.
As used here, ethics are those rules of behavior in relating to other individuals; ethics is individual morality applied to living life in society.