3217 - I2P(I)2025_Chou_Hu_Hw2_ClassA Scoreboard

Time

2025/09/08 20:30:00 2025/09/15 18:30:00

Clarification

# Problem Asker Description Reply Replier Reply Time For all team

# Problem Pass Rate (passed user / total user)
14671 Gaura Nitai
14673 The Cipher of Vyasa Dev

14671 - Gaura Nitai   

Description

Gaura and Nitai were known for their joyful teamwork, often turning ordinary moments into something fresh and harmonious. Inspired by this, imagine a word game they play: Gaura picks a part of the text (between indices l and r), and Nitai playfully shifts that piece to the end of the string. The rest of the words remain in place, showing how change can still keep balance.

 

 

 The Mercy of Sri Gaura and Sri Nityananda, May 31, Potomac ...

 

 

Task:
Given a string s and two integers l and r, move the substring s[l…r] to the end of the original string. The rest of the string should remain in the same order.

 

HINT: 

Refer to this article for an explanation of Python slicing. 

Refer to this article to learn how to receive multiple inputs in one line.

 

Input

  • The first line contains the string s (may contain spaces).
  • The second line contains two non-negative integers, start and end (l and r), separated by a space. These define the inclusive indices of the substring to move (zero-indexed)

Output

  • The modified string after moving the substring to the end. (with a newline)

Sample Input  Download

Sample Output  Download




Discuss




14673 - The Cipher of Vyasa Dev   

Description

You’ve been unexpectedly transported back in time to an ancient world, long before the advent of modern technology. You’ve discovered that Vyasa Dev, a great figure from history, left behind crucial knowledge encoded in numbers. This knowledge was once thought to be too complex to decipher. The people of that time could not solve it because they lacked the tools and mathematical understanding required.

For generations, the encoded knowledge remained inaccessible, hidden in a series of numbers, each holding a piece of a great puzzle. But now, with your modern laptop and coding skills, the challenge is no longer impossible. What was once a monumental task can now be solved quickly with the power of technology.

 

                                    Open photo

 

The knowledge is hidden in the even indices of the number, and you must calculate the sum of these digits to solve the puzzle. Without your ability to code, this problem would have remained unsolved for centuries. But with your help, the knowledge Vyasa Dev left behind is finally within reach.

 

TASK: 

Find the sum of all EVEN indices (0-Indexed)

EXAMPLE:

Given the number 123456, the digits at the even indices (0, 2, 4) are:

  • Index 0: 1

  • Index 2: 3

  • Index 4: 5

The sum of these digits is: 1 + 3 + 5 = 9

Input

A single line of numbers.

Output

Sum of digits at even indices followed by a newline.

Sample Input  Download

Sample Output  Download




Discuss