You asked
What second lens should I pair with a pentax k 50 for portraits and landscapes?
For a K-50, the guide's advice is to add a fast standard prime for people and a wide lens for landscapes, as in your first lenses. On this APS-C body, a 55mm lens frames like about 82mm on full frame, close to the classic portrait length.
For portraits, the Pentax smc DA* 55mm f/1.4 SDM is the strongest pick. Its wide aperture gives soft backgrounds and good subject separation, and it is still light enough to carry all day. It gives up the cost savings of the cheaper options. If budget matters more, the Pentax smc DA 50mm f/1.8 is a simpler, lighter alternative that still gives a flattering portrait view.
For landscapes, the Pentax HD DA 15mm f/4 ED AL Limited is a small, sharp wide prime that frames like 22mm on full frame. It is easy to carry, but you can't zoom, so you move your feet to change the framing. If you want more flexibility, the [Pentax smc DA 12-24mm f/4 ED AL [IF]](/gear/lenses/pentax-smc-da-12-24mm-f-4-ed-al-if/) covers from about 18mm to 36mm on full frame, a wider and more versatile range, at the cost of a larger lens and a smaller maximum aperture.
If you want one lens for both jobs, the Pentax HD DA* 16-50mm f/2.8 ED PLM AW is the most flexible. It covers wide landscapes and standard portraits, though the 55mm prime will give more background blur and better low light.
For the portrait and landscape use, the zoom is usually the better first buy, and a prime follows once you know which focal length you use most.
Written by Claude from this site's pages.
From these pages
This answer is for the question above. Each answer is written for the exact question in its address, so a question with its details in it (a budget, what you shoot, what you already have) gets an answer about those details. An answer draws on all 15 pages of the guide and its catalogue of 320 cameras and 1050 lenses. Another question gets its own answer at its own address, as words after /ask/. Or fill in your own: /ask/which-camera-for-{what-you-shoot}-under-{budget}-euros or /ask/which-lens-for-{what-you-shoot}-on-{your-camera}.