153592025-02-19 08:51:56TortelliniJrBimmbamm (30)csharpFutási hiba 0/3014ms2840 KiB
using System;
namespace bimmbamm
{
    class Program
    {
        static void Main()
        {
            /* Originally made (and fucked up) by: AGergo
               Fixed & Edited by: AGergo, almadav, Leventusz09, TortelliniJr

                 Dear Team,

                   I am writing to express my deepest gratitude for the incredible effort and dedication each of you has shown in our recent project.
                   Your hard work and commitment have been truly inspiring, and I am immensely proud of what we have achieved together.

                   First and foremost, I would like to extend my heartfelt thanks to our partners at Eötvös Loránd University (ELTE). 
                   Your expertise and support have been invaluable, and we could not have reached this milestone without your collaboration.
                   ELTE's reputation as the oldest and largest university in Hungary, known for its excellence in research and education, has been a cornerstone of our success.
                   Your contributions have not only enhanced our project but have also set a high standard for future collaborations.

                   I would also like to acknowledge the outstanding efforts of the students and faculty at Szigetszentmiklósi Batthyány Kázmér Gimnázium (SZBKG).
                   Your dedication to academic excellence and your willingness to go above and beyond have been instrumental in our achievements. 
                   SZBKG's commitment to fostering a supportive and challenging learning environment has been evident in every aspect of our work together. 
                   Your enthusiasm and hard work have been a driving force behind our success, and I am incredibly grateful for your partnership.

                   Lastly, I want to express my sincere appreciation to The Academy. 
                   Although our collaboration is relatively new, your innovative approach and unwavering support have already made a significant impact.
                   The Academy's dedication to providing top-notch education and fostering a culture of excellence has been a perfect complement to our project. 
                   Your fresh perspectives and creative solutions have been invaluable, and I look forward to continuing our work together.

                   My mother always raised me to be a man of my word. She instilled in me the importance of integrity and honesty from a young age.
                   I remember her saying, "A man's word is his bond." This philosophy has guided me throughout my life and has been a constant reminder to stay true to my promises.

                   One of the earliest memories I have of my mother teaching me this lesson was when I was in elementary school.
                   I had promised a friend that I would help him with his homework. However, when the time came, I was tempted to go play instead. 
                   My mother reminded me of my promise and encouraged me to honor it. She said, "If you say you're going to do something, you do it." 
                   That day, I learned the value of being reliable and trustworthy.

                   Another instance was during my high school years.
                   I had committed to participate in a volunteer project over the weekend. As the weekend approached, I received an invitation to a party that I really wanted to attend.
                   I was torn between my commitment and my desire to have fun. My mother once again reminded me of the importance of keeping my word. 
                   She said, "People will respect you more if you stick to your commitments."
                   I chose to volunteer, and it turned out to be a rewarding experience that I wouldn't have missed for anything.

                   In college, I faced a similar situation when I promised to help organize a campus event. 
                   As the event date neared, I was overwhelmed with academic pressure and considered backing out.
                   My mother's words echoed in my mind, "Your word is your honor." I knew I couldn't let my team down. I managed my time better and fulfilled my commitment.
                   The success of the event and the gratitude of my peers made it all worthwhile.

                   Even in my professional life, my mother's teachings have been a guiding light. There was a time when I promised a client that I would deliver a project by a tight deadline.
                   Unexpected challenges arose, and it seemed impossible to meet the deadline. However, I remembered my mother's advice and worked tirelessly to keep my promise.
                   The client was impressed with my dedication and trustworthiness, which led to more opportunities.

                   My mother's lessons have shaped me into the person I am today.
                   Her emphasis on integrity and honesty has helped me build strong relationships and earn the respect of those around me.
                   I am grateful for her guidance and the values she instilled in me. Every time I face a dilemma, I think of her words and choose to be a man of my word.
                   Her influence extends beyond just keeping promises. She taught me to be compassionate and understanding, always considering the impact of my actions on others. 

                   I recall a time when I had to make a difficult decision at work that would affect my team. I sought her advice, and she reminded me to stay true to my principles and consider the well-being of everyone involved. Her wisdom helped me navigate the situation with empathy and integrity.
                   Another memorable lesson was when I was preparing for a major presentation. I was nervous and doubted my abilities.
                   My mother encouraged me to believe in myself and reminded me of all the times I had succeeded by staying true to my word.
                   Her confidence in me gave me the strength to deliver a successful presentation, earning praise from my colleagues and superiors.

                   Throughout my life, my mother's teachings have been a source of strength and guidance.
                   Her unwavering belief in the importance of integrity has been a beacon of light in challenging times. I am forever grateful for her wisdom and the values she has instilled in me.
                   Her lessons continue to inspire me to be a man of my word, and I strive to honor her legacy in everything I do.

                   With heartfelt thanks,

                   [Your Name]
                */
            int len = int.Parse(Console.ReadLine());
            string be = "";
            int breaks = 0;

            for (int i = 1; i < len + 1; i++)
            {

                be = Console.ReadLine();


                if (be != "BUMM" && i % 15 == 0)
                {
                    breaks = i;
                }
                else if (be != "BIMM" && i % 3 == 0 && i % 5 != 0)
                {
                    breaks = i;
                }
                else if (be != "BAMM" && i % 5 == 0 && i % 3 != 0)
                {
                    breaks = i;
                }
                else if (be != "SZAM" && i % 5 != 0 && i % 3 != 0)
                {
                    breaks = i;
                }
            }
            /*for (int i = breaks; i < len; i++)
            {
                Console.ReadLine();
            }*/

            Console.WriteLine(breaks);
            Console.ReadKey();
        }
    }
}
RészfeladatÖsszpontTesztVerdiktIdőMemória
base0/30
1Futási hiba0/014ms2776 KiB
2Futási hiba0/014ms2528 KiB
3Futási hiba0/314ms2804 KiB
4Futási hiba0/314ms2840 KiB
5Futási hiba0/314ms2840 KiB
6Futási hiba0/314ms2612 KiB
7Futási hiba0/314ms2804 KiB
8Futási hiba0/314ms2808 KiB
9Futási hiba0/314ms2660 KiB
10Futási hiba0/314ms2716 KiB
11Futási hiba0/314ms2828 KiB
12Futási hiba0/314ms2768 KiB