Concept:
Carboxylic acids react with ammonia to form ammonium salts, which on heating form amides. Amides undergo Hofmann bromamide degradation to give amines containing one carbon atom less.
Step 1: Formation of acetamide.
\[
CH_3COOH + NH_3
\rightarrow
CH_3COONH_4
\]
Ammonium acetate is formed.
On heating,
\[
CH_3COONH_4
\rightarrow
CH_3CONH_2 + H_2O
\]
Thus
\[
X=CH_3CONH_2
\]
(acetamide)
Step 2: Apply Hofmann bromamide reaction.
\[
CH_3CONH_2
\xrightarrow{Br_2/NaOH}
CH_3NH_2
\]
The carbonyl carbon is removed as \(CO_2\).
Step 3: Identify the final product.
The product obtained is
\[
CH_3NH_2
\]
which is methylamine.
\[
\boxed{Y=CH_3NH_2}
\]