F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

A Strange Problem

Time Limit: 6000/3000 MS (Java/Others)    Memory Limit: 32768/32768 K (Java/Others)
Total Submission(s): 700    Accepted Submission(s): 179


Problem Description
You are given a strange problem. First you have got a sequence contains $N$ integers $A_{1},A_{2},A_{3},...A_{N}$.Then you should perform a sequence of $M$ operations. An operation can be one of the following:

1. Print operation $l,r$ . Print the value of $\sum\limits_{i=l}^{r}A_{i}$.
2. Modify operation $x$. Modify $A_{x}$ to ${2}^{A_{x}}$
3. Add operation $l,r,x$. Add $x\: to\: A_{i}(l\leq i\leq r)$.

As the value of print operation can be rather large, print the remainder after dividing the number by $2333333$.
 

Input
There are several test cases.
In each test case:
The first line contains two integers $N,M(1\leq N,M\leq 50000)$.
The second line contains $N$ integers $A_{1},A_{2},A_{3},...A_{N}(1\leq A_{i}\leq {10}^{9},1\leq i\leq N)$
Each of the next $M$ lines begin with a number $type(1\leq type\leq 3)$.
If $type=1$, there will be two integers more in the line: $l,r(1\leq l\leq r\leq N)$, which correspond the operation 1.
If $type=2$, there will be one integer more in the line: $x(1\leq x\leq N)$, which correspond the operation 2.
If $type=3$, there will be three integers more in the line: $l,r,x(1\leq l\leq r\leq N,1\leq x\leq {10}^{9})$, which correspond the operation 3.
 

Output
For each Print operation, output the remainder of division of the value by $2333333$.
 

Sample Input
3 4 1 2 3 2 3 1 2 3 3 1 3 2 1 1 3 2 2 5 2 2 1 1 1 2
 

Sample Output
10 17 34
 

Source
 

Statistic | Submit | Discuss | Note
Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2024 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2024-04-23 19:31:38, Gzip enabled