C# Corner
Tech
News
Videos
Forums
Trainings
Books
Events
More
Interviews
Jobs
Live
Learn
Career
Members
Blogs
Challenges
Certifications
Bounties
Contribute
Article
Blog
Video
Ebook
Interview Question
Collapse
Feed
Dashboard
Wallet
Learn
Achievements
Network
Refer
Rewards
SharpGPT
Premium
Contribute
Article
Blog
Video
Ebook
Interview Question
Register
Login
Multiply Two Numbers Without Using * Operator
WhatsApp
Atul Rawat
Aug 25
2014
2.9
k
0
1
using
System;
using
System.Collections.Generic;
using
System.Linq;
using
System.Text;
using
System.Threading.Tasks;
namespace
multiplytwonumber
{
class
Program
{
static
void
Main(
string
[] args)
{
Console.WriteLine(
"enter first number"
);
int
num1 = Convert.ToInt32(Console.ReadLine());
Console.WriteLine(
"enter second number"
);
int
num2 = Convert.ToInt32(Console.ReadLine());
int
mul=0;
for
(
int
i = 0; i < num2; i++)
{
mul = mul + num1;
}
Console.WriteLine(mul);
Console.ReadKey();
}
}
}
Multiply number without using operator
C# Programming
Up Next
Multiply Two Numbers Without Using * Operator