Бодолт илгээх | Бүх бодолтууд | Шилдэг бодолтууд | Жагсаалт руу буцах |
RGB7211 - Тооны зэргийн хүрд |
a тооны n хүртэлх зэрэгтүүдийг жишээн дээрх хэлбэрээр хэвлэ.
Input
a, n натурал тоонууд нэг мөрөнд нэг зайгаар тусгаарлагдан өгөгдөнө. (a,n<10)
Output
Зэргийн хүрдийг хэвлэ.
Example
Input: 3 5 Output: 3^1=3
3^2=9
3^3=27
3^4=81
3^5=243
Нэмсэн: | Bataa |
Огноо: | 2011-06-21 |
Хугацааны хязгаарлалт: | 1s |
Эх кодын хэмжээний хязгаарлалт: | 50000B |
Memory limit: | 1536MB |
Cluster: | Cube (Intel G860) |
Програмчлалын хэлүүд: | ADA95 ASM32 BASH BF C NCSHARP CSHARP C++ 4.3.2 CPP C99 CLPS LISP sbcl LISP clisp D ERL FORTRAN HASK ICON ICK JAVA JS-RHINO JULIA LUA NEM NICE OCAML PAS-GPC PAS-FPC PERL PHP PIKE PRLG-swi PYTHON PYPY3 PYTHON3 RUBY SCALA SCM guile ST TCL WHITESPACE |
hide comments
|
|||||||||||||
2024-12-09 03:42:33
jhuhuhiuuhuh |
|||||||||||||
2024-11-26 18:38:56
#include<iostream> using namespace std; int main() { int a,b,c,d,s=1,t,i,n; cin>>a>>n; for(i=1;i<=n;i++){ s*=a; cout<<a<<"^"<<i<<"="<<s<<endl; } }//ryuu bol gicii |
|||||||||||||
2024-11-16 05:35:36
#include<iostream> using namespace std; int main() { int n,a,u,i = 1; cin>>n>>a; for(u=1;u<=a;u++){ i = i * n; cout << n <<"^" << u <<"=" <<i <<endl<<endl; } } //huul teneg boovni usnuudee |
|||||||||||||
2024-10-31 04:10:34
⢰⡿⠋⠁⠀⠀⠈⠉⠙⠻⣷⣄⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ⠀⠀⠀⠀⢀⣿⠇⠀⢀⣴⣶⡾⠿⠿⠿⢿⣿⣦⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ⠀⠀⣀⣀⣸⡿⠀⠀⢸⣿⣇⠀⠀⠀⠀⠀⠀⠙⣷⡀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀ ⠀⣾⡟⠛⣿⡇⠀⠀⢸⣿⣿⣷⣤⣤⣤⣤⣶⣶⣿⠇⠀⠀⠀⠀⠀⠀⠀⣀⠀⠀ ⢀⣿⠀⢀⣿⡇⠀⠀⠀⠻⢿⣿⣿⣿⣿⣿⠿⣿⡏⠀⠀⠀⠀⢴⣶⣶⣿⣿⣿⣆ ⢸⣿⠀⢸⣿⡇⠀⠀⠀⠀⠀⠈⠉⠁⠀⠀⠀⣿⡇⣀⣠⣴⣾⣮⣝⠿⠿⠿⣻⡟ ⢸⣿⠀⠘⣿⡇⠀⠀⠀⠀⠀⠀⠀⣠⣶⣾⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⡿⠁⠉⠀ ⠸⣿⠀⠀⣿⡇⠀⠀⠀⠀⠀⣠⣾⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⡿⠟⠉⠀⠀⠀⠀ ⠀⠻⣷⣶⣿⣇⠀⠀⠀⢠⣼⣿⣿⣿⣿⣿⣿⣿⣛⣛⣻⠉⠁⠀⠀⠀⠀⠀⠀⠀ ⠀⠀⠀⠀⢸⣿⠀⠀⠀⢸⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⡇⠀⠀⠀⠀⠀⠀⠀⠀ ⠀⠀⠀⠀⢸⣿⣀⣀⣀⣼⡿⢿⣿⣿⣿⣿⣿⡿⣿⣿⡿⠀⠀⠀⠀⠀⠀⠀⠀⠀ ⠀⠀⠀⠀⠀⠙⠛⠛⠛⠋⠁⠀⠙⠻⠿⠟⠋⠑⠛⠋⠀ |
|||||||||||||
2024-10-14 11:41:01
blackperson213cbzd.aternos.me |
|||||||||||||
2024-10-13 16:21:24
Hiij cadahgvi baivl holbogdoj tuslamj awj bolno IG: ratitulation8 |
|||||||||||||
2024-10-13 16:20:31
I love you<3 |
|||||||||||||
2024-09-18 04:34:26
public class BankAccount { private String accountNumber; private double balance; // Constructor to initialize the account number and optional balance public BankAccount(String accountNumber, double initialBalance) { this.accountNumber = accountNumber; this.balance = initialBalance; } // Method to deposit money into the account public void deposit(double amount) { if (amount > 0) { balance += amount; System.out.println("Deposited: $" + amount); } else { System.out.println("Deposit amount must be positive."); } } // Method to withdraw money from the account public void withdraw(double amount) { if (amount > 0 && amount <= balance) { balance -= amount; System.out.println("Withdrew: $" + amount); } else { System.out.println("Insufficient funds or invalid amount."); } } // Method to check the account balance public double checkBalance() { return balance; } // Method to transfer money to another BankAccount public void transfer(BankAccount targetAccount, double amount) { if (amount > 0 && amount <= balance) { withdraw(amount); targetAccount.deposit(amount); System.out.println("Transferred: $" + amount + " to account: " + targetAccount.getAccountNumber()); } else { System.out.println("Insufficient funds or invalid amount."); } } // Getter for account number public String getAccountNumber() { return accountNumber; } // Optional: To get a string representation of the account @Override public String toString() { return "Account Number: " + accountNumber + ", Balance: $" + balance; } } |
|||||||||||||
2024-05-10 04:51:43
#include <bits/stdc++.h> using namespace std; int main() { int a,n,c=1; scanf("%d%d",&a,&n); for(int i=1; i<=n; i++){ for(int b=0; b<i; b++){ c*=a; } printf("%d^%d=%d\n", a, i, c); c=1; } } |
|||||||||||||
2024-05-10 04:50:08
#include <bits/stdc++.h> using namespace std; int main() { int a,n,c=1; scanf("%d%d",&a,&n); for(int i=1; i<=n; i++){ for(int b=0; b<i; b++){ c*=a; } printf("%d^%d=%d\n", a, i, c); c=1; } } |