BaseBKHOA CÔNG NGHỆ THÔNG TIN Vòng YoYo 8Huế, Ngày 18 tháng 11 năm 201 dịch - BaseBKHOA CÔNG NGHỆ THÔNG TIN Vòng YoYo 8Huế, Ngày 18 tháng 11 năm 201 Việt làm thế nào để nói

BaseBKHOA CÔNG NGHỆ THÔNG TIN Vòng

BaseB
KHOA CÔNG NGHỆ THÔNG TIN Vòng YoYo 8
Huế, Ngày 18 tháng 11 năm 2016 BaseB
Traditionally numbers are written in base 10 ("decimal"). That is, every digit is a number
between 0 and 9. We think of a number as its decimal representation. However, as you might
know, numbers can be written in base b for any b > 0. In this case, every digit is a number
between 0 and b-1. For instance in base 4 we may write 3312 or 30.
The value of a number written in base b is determined as follows: Suppose the given number
in base b is d
n−1
...d
0
where each d
lies between 0 and b-1. This represents the number:
d
0
+ d
1
∗ b + d
2
∗ b
2
+ ... + d
i
∗ b
i
i
+ ... + d
n−1
∗ b
n−1
We don’t permit leading 0’s in the representation. For instance, we cannot write 003312 or
03312 instead of 3312.
Given a number in decimal one can compute the base b representation by inverting the above
computation.
It is easy to check that the base 4 representation 3312 denotes the decimal number 246 and
the base 4 representation 30 denotes 12. Similarly, the base 12 representation 2 11 10 (where
we use blank spaces to separate the digits) denotes the decimal number 430 while the base
12 representation 3 0 2 denotes the number 434.
Nhiệm vụ:
You will be given b and the base b representation of two numbers A and B. Your task is to
printout the base b representation of the product A ×B.
For example the product of the base 4 numbers 3312 and 30 written in base 4 is 232020.
Similarly, the product of the base 12 numbers 2 11 10 and 3 0 2 written in base 12 is 8 11 11
11 8.
Dữ liệu vào:
The first line of the input contains 3 integers b, N and M, where b is the base. N and M are
the number of digits in the representation (in base b) of the two given numbers. The second
line contains N space separated integers D
giving the base b representation
of the first number and the third line contains M space separated integers E
N−1
giving the base b representation of the second number.
Dữ liệu ra:
, D
N−2
...D
0
The first line of the output should be a single integer L denoting the length of the base
b representation of the product. The second line should contain L space separated integers
giving the base b representation of the product.
Các ví dụ:
Page 1 of 2
M−1
, E
M−2
...E
0
KHOA CÔNG NGHỆ THÔNG TIN Vòng YoYo 8
Huế, Ngày 18 tháng 11 năm 2016 BaseB
Dữ liệu vào: Dữ liệu ra:
4 4 2
3 3 1 2
3 0
6
2 3 2 0 2 0
Dữ liệu vào: Dữ liệu ra:
12 3 3
2 11 10
3 0 2
Ràng buộc:
Value: 1 ≤ N, M ≤ 1000.
Time limit: 1000 ms.
Memory limit : 32 MB.
Page 2 of 2
5
8 11 11 11 8
0/5000
Từ: -
Sang: -
Kết quả (Việt) 1: [Sao chép]
Sao chép!
BaseBKHOA CÔNG NGHỆ THÔNG TIN Vòng YoYo 8Huế, Ngày 18 tháng 11 năm 2016 BaseBTraditionally numbers are written in base 10 ("decimal"). That is, every digit is a numberbetween 0 and 9. We think of a number as its decimal representation. However, as you mightknow, numbers can be written in base b for any b > 0. In this case, every digit is a numberbetween 0 and b-1. For instance in base 4 we may write 3312 or 30.The value of a number written in base b is determined as follows: Suppose the given numberin base b is dn−1...d0where each dlies between 0 and b-1. This represents the number:d0+ d1∗ b + d2∗ b2+ ... + di∗ bii+ ... + dn−1∗ bn−1We don’t permit leading 0’s in the representation. For instance, we cannot write 003312 or03312 instead of 3312.Given a number in decimal one can compute the base b representation by inverting the abovecomputation.It is easy to check that the base 4 representation 3312 denotes the decimal number 246 andthe base 4 representation 30 denotes 12. Similarly, the base 12 representation 2 11 10 (wherewe use blank spaces to separate the digits) denotes the decimal number 430 while the base12 representation 3 0 2 denotes the number 434.Nhiệm vụ:You will be given b and the base b representation of two numbers A and B. Your task is toprintout the base b representation of the product A ×B.For example the product of the base 4 numbers 3312 and 30 written in base 4 is 232020.Similarly, the product of the base 12 numbers 2 11 10 and 3 0 2 written in base 12 is 8 11 11
11 8.
Dữ liệu vào:
The first line of the input contains 3 integers b, N and M, where b is the base. N and M are
the number of digits in the representation (in base b) of the two given numbers. The second
line contains N space separated integers D
giving the base b representation
of the first number and the third line contains M space separated integers E
N−1
giving the base b representation of the second number.
Dữ liệu ra:
, D
N−2
...D
0
The first line of the output should be a single integer L denoting the length of the base
b representation of the product. The second line should contain L space separated integers
giving the base b representation of the product.
Các ví dụ:
Page 1 of 2
M−1
, E
M−2
...E
0
KHOA CÔNG NGHỆ THÔNG TIN Vòng YoYo 8
Huế, Ngày 18 tháng 11 năm 2016 BaseB
Dữ liệu vào: Dữ liệu ra:
4 4 2
3 3 1 2
3 0
6
2 3 2 0 2 0
Dữ liệu vào: Dữ liệu ra:
12 3 3
2 11 10
3 0 2
Ràng buộc:
Value: 1 ≤ N, M ≤ 1000.
Time limit: 1000 ms.
Memory limit : 32 MB.
Page 2 of 2
5
8 11 11 11 8
đang được dịch, vui lòng đợi..
Kết quả (Việt) 2:[Sao chép]
Sao chép!
BaseB
KHOA CÔNG NGHỆ THÔNG TIN Vòng YoYo 8
Huế, Ngày 18 tháng 11 năm 2016 BaseB
Theo truyền thống số được viết trong cơ sở 10 ( "thập phân"). Đó là, mỗi chữ số là một số
từ 0 đến 9. Chúng tôi nghĩ ra một số như là đại diện thập phân của nó. Tuy nhiên, như bạn có thể
biết, con số có thể được viết trong cơ sở b cho bất kỳ b> 0. Trong trường hợp này, mỗi chữ số là một số
giữa 0 và b-1. Ví dụ trong cơ sở 4, chúng tôi có thể viết 3312 hoặc 30.
Giá trị của một số văn bản trong cơ sở b được xác định như sau: Giả sử số lượng nhất định
trong cơ sở b là d
n-1
... d
0
, nơi mỗi d
nằm giữa 0 và b-1. Điều này thể hiện số lượng:
d
0
+ d
1
* b + d
2
* b
2
+ ... + d
i
* b
i
i
+ ... + d
n-1
* b
n-1
Chúng tôi không cho phép nhập số 0 đầu của trong các đại diện. Ví dụ, chúng ta không thể viết 003.312 hoặc
03.312 thay vì 3312.
Cho một số trong một số thập phân có thể tính các đại diện cơ sở b bằng cách đảo ngược trên
tính toán.
Nó rất dễ dàng để kiểm tra các cơ sở 4 đại diện 3312 là số thập phân 246 và
các cơ sở 4 đại diện 30 biểu thị 12. Tương tự như vậy, các cơ sở đại diện 12 2 11 10 (mà
chúng ta sử dụng khoảng trống để tách các chữ số) biểu thị số thập phân 430 trong khi các cơ sở
12 đại diện 3 0 2 là số 434.
nhiệm vụ:
Bạn sẽ nhận được b và các đại diện cơ sở b của hai số A và B. nhiệm vụ của bạn là để
in ra các đại diện cơ sở b của sản phẩm A × b.
Ví dụ các sản phẩm của các cơ sở 4 số 3312 và 30 văn bản trong cơ sở 4 là 232020.
Tương tự như vậy, các sản phẩm của các cơ sở 12 số 2 11 10 3 0 2 văn bản trong cơ sở 12 8 11 11
11 8.
Dữ liệu vào:
dòng đầu tiên của input chứa 3 số nguyên b, N và M, trong đó b là cơ sở. N và M là
số các chữ số trong các đại diện (trong cơ sở b) của hai số cho trước. Thứ hai
dòng chứa N số nguyên không gian tách D
cho các đại diện cơ sở b
của số đầu tiên và dòng thứ ba chứa M không gian tách nguyên tử
N-1
cho các đại diện cơ sở b của số thứ hai.
Dữ liệu ra:
D
N-2
... D
0
Dòng đầu tiên của đầu ra phải là một số nguyên L đơn biểu thị độ dài của các cơ sở
đại diện b của sản phẩm. Dòng thứ hai chứa L không gian tách biệt các số nguyên
cho các đại diện cơ sở b của sản phẩm.
Các example:
Trang 1 của 2
M-1
, E
M-2
... E
0
KHOA CÔNG NGHỆ THÔNG TIN Vòng YoYo 8
Huế, Ngày 18 tháng 11 năm 2016 BaseB
data vào: Dữ liệu ra:
4 4 2
3 3 1 2
3 0
6
2 3 2 0 2 0
Dữ liệu vào: Dữ liệu ra:
12 3 3
2 11 10
3 0 2
Ràng buộc:
Giá trị: 1 ≤ N, M ≤ 1000.
Thời hạn: 1000 ms.
Giới hạn bộ nhớ: 32 MB.
Trang 2 của 2
5
8 11 11 11 8
đang được dịch, vui lòng đợi..
 
Các ngôn ngữ khác
Hỗ trợ công cụ dịch thuật: Albania, Amharic, Anh, Armenia, Azerbaijan, Ba Lan, Ba Tư, Bantu, Basque, Belarus, Bengal, Bosnia, Bulgaria, Bồ Đào Nha, Catalan, Cebuano, Chichewa, Corsi, Creole (Haiti), Croatia, Do Thái, Estonia, Filipino, Frisia, Gael Scotland, Galicia, George, Gujarat, Hausa, Hawaii, Hindi, Hmong, Hungary, Hy Lạp, Hà Lan, Hà Lan (Nam Phi), Hàn, Iceland, Igbo, Ireland, Java, Kannada, Kazakh, Khmer, Kinyarwanda, Klingon, Kurd, Kyrgyz, Latinh, Latvia, Litva, Luxembourg, Lào, Macedonia, Malagasy, Malayalam, Malta, Maori, Marathi, Myanmar, Mã Lai, Mông Cổ, Na Uy, Nepal, Nga, Nhật, Odia (Oriya), Pashto, Pháp, Phát hiện ngôn ngữ, Phần Lan, Punjab, Quốc tế ngữ, Rumani, Samoa, Serbia, Sesotho, Shona, Sindhi, Sinhala, Slovak, Slovenia, Somali, Sunda, Swahili, Séc, Tajik, Tamil, Tatar, Telugu, Thái, Thổ Nhĩ Kỳ, Thụy Điển, Tiếng Indonesia, Tiếng Ý, Trung, Trung (Phồn thể), Turkmen, Tây Ban Nha, Ukraina, Urdu, Uyghur, Uzbek, Việt, Xứ Wales, Yiddish, Yoruba, Zulu, Đan Mạch, Đức, Ả Rập, dịch ngôn ngữ.

Copyright ©2024 I Love Translation. All reserved.

E-mail: