The Gemara answers: A mitzva is different, and since it is a mitzva to put on phylacteries, the mourner is required to do so, even during the first three days.
ת"ר אבל ג' ימים הראשונים אסור במלאכה ואפילו עני המתפרנס מן הצדקה מכאן ואילך עושה בצינעא בתוך ביתו והאשה טווה בפלך בתוך ביתה
§ The Sages taught the following baraita: During the first three days after his bereavement, a mourner is prohibited from working, even if he is a poor person who is supported by charity. From this point forward, he may do work privately in his own home if he needs to do so. And similarly a woman may spin thread on a spindle in her own home when she is mourning.
ת"ר אבל ג' ימים הראשונים אינו הולך לבית האבל מכאן ואילך הולך ואינו יושב במקום המנחמין אלא במקום המתנחמין
The Sages taught in another baraita: A mourner during the first three days after his bereavement may not go to another mourner’s house to console him. From this point forward, he may go, but he may not sit among the consolers, but rather in the place of those being consoled, i.e., with the mourners in that house.
תנו רבנן אבל ג' ימים הראשונים אסור בשאילת שלום משלשה ועד שבעה משיב ואינו שואל מכאן ואילך שואל ומשיב כדרכו
§ The Sages taught in yet another baraita: A mourner, during the first three days after his bereavement, is prohibited from extending greetings to others. From the third day to the seventh day, he may respond when other people address him, but he may not extend greetings to them. From this point forward, he may extend greetings and respond in his usual manner.”
שלשה ימים הראשונים אסור בשאילת שלום והתניא מעשה ומתו בניו של ר"ע נכנסו כל ישראל והספידום הספד גדול
The Gemara asks: Is he really prohibited from extending greetings during the first three days of mourning? But isn’t it taught in a baraita: There was an incident and the sons of Rabbi Akiva died, and all the Jews entered to eulogize them with a great eulogy.
בשעת פטירתן עמד ר"ע על ספסל גדול ואמר אחינו בית ישראל שמעו אפי' שני בנים חתנים מנוחם הוא בשביל כבוד שעשיתם ואם בשביל עקיבא באתם הרי כמה עקיבא בשוק אלא כך אמרתם (תהלים לז, לא) תורת אלהיו בלבו וכ"ש ששכרכם כפול לכו לבתיכם לשלום
When they were about to take leave, Rabbi Akiva stood on a large bench and said: Our brothers, the house of Israel, listen! Even had my two sons been bridegrooms, I would have been consoled on account of the honor you have shown them. If you came to console for the sake of Akiva, there are many Akivas in the marketplace whom the Jews do all not come to console. Rather, certainly this is what you said to yourselves: “The Torah of his God is in his heart” (Psalms 37:31), and you wished to show your respect for the Torah. All the more so is your reward doubled, for you have consoled mourners and shown respect for the Torah. Return now to your homes in peace. This indicates that a mourner may greet other people even on the first day of his mourning.
כבוד רבים שאני
The Gemara answers: Showing respect for the public is different. Rabbi Akiva was permitted to greet them to demonstrate courtesy and respect.
מג' ועד ז' משיב ואינו שואל מכאן ואילך שואל ומשיב כדרכו
§ It was taught in the aforementioned baraita: From the third day to the seventh day, he may respond when other people address him, but he may not extend greetings to them. From this point forward, he may extend greetings and respond in his usual manner.
ורמינהו המוצא את חבירו אבל בתוך ל' יום מדבר עמו תנחומין ואינו שואל בשלומו לאחר ל' יום שואל בשלומו ואינו מדבר עמו תנחומין
And the Gemara raises a contradiction from another baraita that states: One who finds another in mourning during the first thirty days of that person’s bereavement may still speak words of consolation to him, but he should not extend greetings toward him. If he finds him after thirty days, he may extend greetings toward him, but he should not speak words of consolation to him, so as not to remind him of his pain.
מתה אשתו ונשא אשה אחרת אינו רשאי ליכנס לביתו לדבר עמו תנחומין מצאו בשוק אומר לו בשפה רפה ובכובד ראש
If it was the mourner’s wife who died and he married another woman within thirty days of his first wife’s death, one may not enter his house to speak words of consolation with him, so as not to offend his new wife. If, however, he finds him alone in the marketplace, he may speak to him with gentle words and in a serious manner. This indicates that the prohibition against extending greetings lasts for thirty days and not just seven.
אמר רב אידי בר אבין הוא שואל בשלום אחרים שאחרים שרויין בשלום אחרים אין שואלין בשלומו שהוא אינו שרוי בשלום
Rav Idi bar Avin said: The two baraitot refer to different situations: The first baraita is referring to the mourner himself, who may extend greetings [shalom] to others after the completion of his seven days of mourning, as the others are at peace [shalom]. The second baraita, which speaks of a prohibition that lasts thirty days, is referring to other people, who may not extend greetings to him, as he, the mourner, is not at peace.
והא מדקתני משיב מכלל דשיילינן ליה דלא ידעי
The Gemara challenges: But from the fact that it teaches in a baraita that after the third day of his bereavement, the mourner may respond when other people address him, by inference others may extend greetings to him. The Gemara answers: This is referring to a case where people did not know that he was in mourning and unknowingly extended greetings to him.
אי הכי התם נמי התם מודע להו ולא מהדר להו הכא לא צריך לאודועינהו
The Gemara asks: If so, if the baraita speaks of a case where the people who greeted him were unaware that he was in mourning, then there also, during the first three days of his bereavement, he should be permitted to respond when other people address him. The Gemara answers: There, during the first three days, he must inform them that he is in mourning and not respond to their greetings. Here, after the first three days, he need not inform them about his bereavement, but rather he may respond to their greetings.
ורמינהו המוצא את חברו אבל בתוך י"ב חדש מדבר עמו תנחומין ואינו שואל בשלומו לאחר י"ב חדש שואל בשלומו ואינו מדבר עמו תנחומין אבל מדבר עמו מן הצד
And the Gemara raises a contradiction from another baraita that states: One who finds another in mourning during his twelve months of bereavement may still speak words of consolation to him, but he should not extend greetings toward him. If he finds him after twelve months, he may extend greetings toward him, and he should not speak words of consolation to him. He may, however, speak to him indirectly, i.e., he may say to him: May you be consoled, without mentioning the name of the deceased.
א"ר מאיר המוצא את חברו אבל לאחר י"ב חדש ומדבר עמו תנחומין למה הוא דומה לאדם שנשברה רגלו וחיתה מצאו רופא ואמר לו כלך אצלי שאני שוברה וארפאנה כדי שתדע שסממנין שלי יפין
Rabbi Meir said: One who finds another in mourning after twelve months and speaks to him words of consolation, to what may this situation be likened? To a person who broke his leg and it healed, and afterward a physician found him and said to him: Come to me, for I will break it a second time and then I will heal it, so that you may know how good my medicines are and how well they work. One who consoles his friend after so much time has passed acts in a similar fashion, stirring up an old wound and then trying to heal it. In any event, it appears that one must not extend greetings to a mourner during the entire twelve-month mourning period.
לא קשיא הא באביו ואמו הא בשאר קרובים
The Gemara answers: This is not difficult. This baraita, which says that one must not extend greetings to a mourner for twelve months, is referring to one who lost his father or mother. That baraita, which teaches that a mourner may be greeted after seven days, is referring to one who is in mourning over other relatives.
התם נמי ידבר עמו תנחומין מן הצד אין ה"נ ומאי אינו מדבר עמו תנחומין כדרכו אבל מדבר עמו מן הצד
The Gemara asks: There too, in the case of other relatives after thirty days, let him speak words of consolation to him indirectly. Why does the baraita say that after thirty days he should not speak words of consolation to him at all? The Gemara answers: Yes, it is indeed so. And what is meant by the words: He should not speak words of consolation to him? This means that he may not console him in his usual manner, but he may speak to him indirectly.
ת"ר אבל ג' ימים הראשונים בא ממקום קרוב מונה עמהן בא ממקום רחוק מונה לעצמו מכאן ואילך אפי' בא ממקום קרוב מונה לעצמו ר"ש אומר אפי' בא ביום השביעי ממקום קרוב מונה עמהן
§ The Sages taught the following baraita: If a mourner comes to the house of mourning from a nearby place during the first three days of mourning, he counts his days of mourning with the other mourners from the time of the burial and completes his mourning with them. This is the case even if he may end up observing mourning for only five or six days. But if he came from a distant place, he counts on his own seven complete days from the time that he was informed of his relative’s death. From this point forward, i.e., after the first three days of mourning, even if he came from a nearby place, he counts seven days on his own. Rabbi Shimon says: Even if he came on the seventh day from a nearby place, he counts and completes the seven-day period of mourning with the other mourners.
אמר מר ג' ימים הראשונים בא ממקום קרוב מונה עמהן א"ר חייא בר אבא א"ר יוחנן והוא שיש גדול הבית בבית
The Master said, citing the baraita: If a mourner comes to the house of mourning from a nearby place during the first three days of mourning, he counts his days of mourning with the other mourners and completes his mourning with them. Rabbi Ḥiyya bar Abba said that Rabbi Yoḥanan said: This is in a case where the principal member of the household is in the house, and therefore all the other family members follow his mourning. If, however, it is the principal member of the family who comes home, he certainly does not follow the other members, but rather he counts seven days on his own.
A dilemma was raised before the scholars: