What social and economic problems did new immigrants (primarily from Europe) to the U.S. encounter from the 1840s until World War I?
The immigrants who came largely from Europe during the period that you are asking about in this question encountered many problems.
They typically encountered economic problems. These problems arose from the fact that many of them came without any skills, without the ability to speak English, or both. What these facts did was force them to take the hardest and worst jobs available in the United States. Because they had to take these jobs, many of them were very poor. This meant that they lived and worked in very difficult conditions.
The immigrants also faced a variety of what could be called social problems. Let us look at the two most important of these here. First, they faced the problem of learning to get along in a new country. They had to learn a new language and new customs. They had to deal with the emotional problems that come from having left one’s home. All of this was difficult. Second, they had to deal with nativism from the Americans. Most immigrants were hated for one reason or another. Americans looked down on them because of their religion or their customs. They generally thought the immigrants were ruining the country and they treated them accordingly.
Thus, the immigrants faced many difficult problems in these years.