Computer Science, asked by likithakaruturi, 8 months ago

We all know that Hermione is really good at her studies. She is always the topper of the class. However, recently another student, Luna has started
topping the class.
Hermione finds out that Luna isn't really better than her at studies, she is just taking some special potions, which helps her get better marks.
With every drink of the potion, Luna is able to multiply her marks by k. She even maintains a calendar in the form of a string. Prefers to potion,
and E refers to exam.
Initially, Luna has the ability to get A marks in her exam.
Let's say A is 5 and kis 3.
If her calendar is as follows: PEPEEPE , it means:
1. She drinks a potion, and her ability becomes 15. Therefore in first exam she scores 15
2. Then she drinks a potion, and her ability becomes 45. There in 2nd and 3rd exam, she scores 45 in each
3. And in final exam she is able to score 135
Hermione can distort this calendar. At any time, she can switch around any 2 adjacent events. She wants to know how many swaps of adjacent
characters she should do, such that Luna's score becomes lesser than Hermione's marks H.​

Answers

Answered by Anonymous
0

Answer:

This is the book smart/hidden beauty student. The one that you really don’t notice until senior year once prom time comes around. Why don’t you notice her? Because most of the time she was buried in one book or another or participating in a club you had no idea existed. Hermione was intelligent, resourceful, and can get pretty feisty if you try screwing her over. Essentially she’s the apex of all human achievement, “the brightest witch of her age.” Let’s not forget she brewed an illegal potion at age 12 and used time travel just so she could take more classes. Meet: Hermione Granger.

Similar questions