Arsip: Aplikasi konversi Biner desimal

more 14 years ago
ilhuna
Halo halooo..
ada yang tau gak, membuat aplikasi konversi dari decimal ke binary atau sebaliknya dari binary(biner) ke decimal dengan menggunakan program delphi????????

more 14 years ago
aday-gate
nambahin
http://fajardelphiscript.blogspot.com/2009/07/konversi-bilangan-dengan-delphi.html
nih yang paling bagus

more 14 years ago
reev
procedure TForm5.Button1Click(Sender: TObject);
var
bin: String;
intg: Integer;
begin
intg:=StrToInt(Edit1.Text);
//convert to bin
bin:='';
repeat
if (intg and 1) = 1 then
bin:='1'+bin
else
bin:='0'+bin;
intg:= intg shr 1;
until intg = 0;
Edit2.Text:=bin;
//convert back
intg:=0;
repeat
intg:=intg shl 1;
if bin[1]='0' then
Intg:=intg or 0
else
Intg:=intg or 1;
delete(bin,1,1);
until bin = '';
//result
Edit3.Text:=IntToStr(intg);
end;

more 14 years ago
reev
Payah geshi, tanda + kok hilang. Nih, yang biasa aja:
procedure TForm5.Button1Click(Sender: TObject);
var
bin: String;
intg: Integer;
begin
intg:=StrToInt(Edit1.Text);
//convert to bin
bin:='';
repeat
if (intg and 1) = 1 then
bin:='1'+bin
else
bin:='0'+bin;
intg:= intg shr 1;
until intg = 0;
Edit2.Text:=bin;
//convert back
intg:=0;
repeat
intg:=intg shl 1;
if bin[1]='0' then
Intg:=intg or 0
else
Intg:=intg or 1;
delete(bin,1,1);
until bin = '';
//result
Edit3.Text:=IntToStr(intg);
end;
more ...
- Pages:
- 1
reply |
Report Obsolete
AI Forward

🚀 We're thrilled to partner with Alibaba Cloud for "AI Forward - Alibaba Cloud Global Developer Summit 2025" in Jakarta! Join us and explore the future of AI. Register now:
https://int.alibabacloud.com/m/1000400772/
#AlibabaCloud #DeveloperSummit #Jakarta #AIFORWARD
Last Articles
Last Topic
- PascalTalk #6: (Podcast) Kuliah IT di luar negeri, susah gak sih?
by LuriDarmawan in Tutorial & Community Project more 4 years ago - PascalTalk #5: UX: Research, Design and Engineer
by LuriDarmawan in Tutorial & Community Project more 4 years ago - PascalTalk #4: Obrolan Ringan Seputar IT
by LuriDarmawan in Tutorial & Community Project more 4 years ago - PascalTalk #2: Membuat Sendiri SMART HOME
by LuriDarmawan in Tutorial & Community Project more 4 years ago - PascalTalk #3: RADically Fast and Easy Mobile Apps Development with Delphi
by LuriDarmawan in Tutorial & Community Project more 4 years ago - PascalTalk #1: Pemanfaatan Artificial Intelligence di Masa Covid-19
by LuriDarmawan in Tutorial & Community Project more 4 years ago - Tempat Latihan Posting
by LuriDarmawan in OOT more 5 years ago - Archive
- Looping lagi...
by idhiel in Hal umum tentang Pascal Indonesia more 12 years ago - [ask] koneksi ke ODBC user Dsn saat runtime dengan ado
by halimanh in FireBird more 12 years ago - Validasi menggunakan data tanggal
by mas_kofa in Hal umum tentang Pascal Indonesia more 12 years ago
Random Topic
- Which One is The Best 4 DBase Apps Delphi /VB/Visual FoxPro
by frans_jp in Hal umum tentang Pascal Indonesia more 18 years ago - tanya soal quick report
by Computer(Insane) in Tip n Trik Pemrograman more 18 years ago - sendkey
by ahariono in Tip n Trik Pemrograman more 17 years ago - jumlah print
by sidiq_himura in Reporting more 16 years ago - suatu saat di kelas delphi
by simba in Hal umum tentang Pascal Indonesia more 18 years ago - Form untuk Master Detail
by deepblue in Tip n Trik Pemrograman more 15 years ago - formatdate
by ags606 in Hal umum tentang Pascal Indonesia more 18 years ago - mohon pencerahannya..
by afre_N in Tip n Trik Pemrograman more 17 years ago - script untuk button dari image
by Charles in OOT more 17 years ago - koneksi data module
by neoruz in Hal umum tentang Pascal Indonesia more 18 years ago