Praying salah with pubic hair longer than 40 days
In the name of Allah, the most Beneficent, the most Merciful.
Saaiduna Abu Huraira narrates that the Prophet of Allah said “Five practices are of Fitra: circumcision, shaving the pubic hair, clipping the nails and cutting the moustache short.” (Sahih Bukhari p.874 v.2)
It is recommended to remove the pubic hair every seven days. It is also permissible to delay this to fifteen days, beyond forty days is Makruh Tahrimi and sinful. (Bashti Zewar p.479)
The hair should not be left longer than forty days. This is because of the hadith narrated by Saaiduna Anas bin Malik who said, “He set us a time limit of no more than forty days for trimming the moustache, clipping the nails, plucking of armpit hairs and shaving the pubic hair.” (Sahih Bukhari & Sahih Muslim)
With regards to your question, the obligation of the salah will be done but you will not receive the full reward of the salah.
Only Allah Knows Best
Mohammed Tosir Miah
Darul Ifta Birmingham