\documentclass[12pt]{article}
\usepackage{a4wide}
\usepackage[T2A]{fontenc}              %%%%%Cyrillic fonts
\usepackage[cp866]{inputenc}           %%%%%for MS DOS coding
%\usepackage[cp1251]{inputenc}         %%%%%for MS Windows coding
%\inputencoding{cp866}
\usepackage[russian]{babel}            %%%%%Russain grammar rules
\usepackage{amsmath,amssymb,latexsym}  %%%%%AMS symbols


\pagestyle{plain}
\righthyphenmin=3
\emergencystretch=4pt
\hfuzz=0.5pt
\tolerance=400


\begin{document}

...

\end{document}