salman posting

Download Salman Posting

Post on 05-Apr-2018

227 views

Category:

Documents

0 download

Embed Size (px)

TRANSCRIPT

  • 8/2/2019 Salman Posting

    1/22

    Posting

    Aktivitas

    Sign In

    Top of Form

    Bottom of Form

    Mencantumkan kode program di posting Anda, tolong ikuti aturan yang

    sesuai, baca http://diskusiweb.com/discussion/39204/aturan-cara-menyisipkan-

    kode-program-di-diskusiweb

    Tolong pilih kategori sesuai, jenis posting (pertanyaan atau bukan) dan sertakan

    tag/topik yang sesuai misal komputer, php, mysql, dll. Promosi atau posting tidak

    pada tempatnya akan kami hapus.

    Diskusi Pemrograman & IT

    Aturan & Cara Menyisipkan Kode Program di Diskusiweb

    adminJanuary 2011

    Posts: 643

    Kalau ingin posting kode dan tampil dengan format sintaks, gunakan tag pre

    dengan atribut lang diisi dengan nama bahasa programnya.

    Contoh:

    < /pre>

    Hasilnya akan jadi seperti berikut:

    http://diskusiweb.com/discussionshttp://diskusiweb.com/activityhttp://diskusiweb.com/entry/signin?Target=discussion%2F39204%2Faturan-cara-menyisipkan-kode-program-di-diskusiwebhttp://diskusiweb.com/discussion/39204/aturan-cara-menyisipkan-kode-program-di-diskusiwebhttp://diskusiweb.com/discussion/39204/aturan-cara-menyisipkan-kode-program-di-diskusiwebhttp://diskusiweb.com/categories/tanya-jawabhttp://diskusiweb.com/profile/1/adminhttp://diskusiweb.com/discussion/39204/aturan-cara-menyisipkan-kode-program-di-diskusiweb/p1http://diskusiweb.com/profile/1/adminhttp://diskusiweb.com/http://diskusiweb.com/activityhttp://diskusiweb.com/entry/signin?Target=discussion%2F39204%2Faturan-cara-menyisipkan-kode-program-di-diskusiwebhttp://diskusiweb.com/discussion/39204/aturan-cara-menyisipkan-kode-program-di-diskusiwebhttp://diskusiweb.com/discussion/39204/aturan-cara-menyisipkan-kode-program-di-diskusiwebhttp://diskusiweb.com/categories/tanya-jawabhttp://diskusiweb.com/profile/1/adminhttp://diskusiweb.com/discussion/39204/aturan-cara-menyisipkan-kode-program-di-diskusiweb/p1http://diskusiweb.com/discussions
  • 8/2/2019 Salman Posting

    2/22

    Skatel_Linux_comJanuary 2011

    Posts: 1,267

    Perl. lang="perl"

    $n = '3

    apples';

    $m = '2oranges';

    print $n + $m;

    Ruby. lang="ruby"

    say['test'] = "saya cinta

    ruby"

    puts say.upcase

    Python. lang="python"

    >>> import math

    >>> print('The value of PI is approximately

    %5.3f.' % math.pi)

    Javascript. lang="javascript"

    for (i=0;i

  • 8/2/2019 Salman Posting

    3/22

    ASP. lang="asp"

    Pascal. lang="pascal"

    procedure MWritei(const i:

    Integer);

    begin

    Write(i);

    end;

    C++. lang="c"

    #include

    int main()

    {

    std::cout

  • 8/2/2019 Salman Posting

    4/22

    Java. lang="java"

    package org.kodejava.example.java.util;

    import java.text.DateFormat;

    import java.text.SimpleDateFormat;

    import java.util.Calendar;

    import java.util.Date;

    public class DateToString

    {

    public static void main(String[] args)

    {

    // Create an instance of SimpleDateFormat usedfor formatting

    // the string representation of date

    (month/day/year)

    DateFormat df = new

    SimpleDateFormat("MM/dd/yyyy");

    // Get the date today using Calendar object.

    Date today = Calendar.getInstance().getTime();

    // Using DateFormat format method we can createa string

    // representation of a date with the defined format.

    String reportDate = df.format(today);

    // Print what date is today!

    System.out.println("Report Date: " + reportDate);

    }

    }

    SQL. lang="sql"

    SELECT *

    INTO new_table_name

    FROM old_tablename;

    SELECT *

    FROM a

    INNER JOIN b

    ON b.id = a.id_bWHERE a.active = 'yes' OR

  • 8/2/2019 Salman Posting

    5/22

    a.active = TRUE

    LIMIT 5;

    Skatel_Linux_comJanuary 2011

    Posts: 1,267

    untuk C++ dan C# belum highlight tuh. :D langnya diisi apa? "ceples-ples" kah?

    "cesarap" kah?

    atau ini diskriminasi syntax highlight dalam bahasa pemrograman. [-(

    yang C udah bisa, entah bener apa ngga. :D

    lockheartJanuary 2011

    Posts: 11

    @Skatel_Linux_com : kren om... ahhahaa

    bisa smua bhsa pemrograman ya om??

    hihihi

    :)

    HusniJanuary 2011

    Posts: 3,255

    lang="vb"

    Public Function TestMethod() As

    Collection

    Dim c As New Collection

    For i As Integer = 0 To 10

    c.Items.Add(i)

    NextTestMethod = c

    End Function

    TestMethod()

    lang="vbnet"

    Public Class TestClass

    Public Shared Function TestMethod() As Collection

    http://diskusiweb.com/profile/8853/Skatel_Linux_comhttp://diskusiweb.com/discussion/comment/236432#Comment_236432http://diskusiweb.com/profile/27480/lockhearthttp://diskusiweb.com/discussion/comment/236677#Comment_236677http://diskusiweb.com/profile/Skatel_Linux_comhttp://diskusiweb.com/profile/3197/Husnihttp://diskusiweb.com/discussion/comment/236778#Comment_236778http://diskusiweb.com/profile/3197/Husnihttp://diskusiweb.com/profile/27480/lockhearthttp://diskusiweb.com/profile/8853/Skatel_Linux_comhttp://diskusiweb.com/profile/8853/Skatel_Linux_comhttp://diskusiweb.com/discussion/comment/236432#Comment_236432http://diskusiweb.com/profile/27480/lockhearthttp://diskusiweb.com/discussion/comment/236677#Comment_236677http://diskusiweb.com/profile/Skatel_Linux_comhttp://diskusiweb.com/profile/3197/Husnihttp://diskusiweb.com/discussion/comment/236778#Comment_236778
  • 8/2/2019 Salman Posting

    6/22

  • 8/2/2019 Salman Posting

    7/22

    lang="cpp"

    class TestClass {

    public static stringTestMethod() {

    return 'Test';

    }

    }

    lang="xml"

  • 8/2/2019 Salman Posting

    8/22

    lang="actionscript"

    class com.test.TestClass extends MovieClip {

    public function TestClass() {}public function onLoad() :Void {

    var txtTest:TextField = this.createTextField("Test", 0,

    0, 0, 100, 100);

    txtTest.text = "Test";

    }

    }

    lang="vbscript"

    ' gak

    kerender

    Dim x As

    String

    x = "Test"

    alert(x)

    lang="jsharp"

    /* gak kerender */

    class TestClass {

    public static string

    TestMethod() {

    return 'Test';

    }

    }

    lang="dos"

    rem Tes Ping

    @echo off

    echo Sedang ngeping detik.com, tekan Ctrl C

    untuk berhenti

    ping detik.com -l 1 -t > detik.txt

    lang="bash"

  • 8/2/2019 Salman Posting

    9/22

    cd /var/www

    echo "php_value magic_quotes_gpc 0"

    > .htaccess

    lang="asm"

    org 100h

    mov ah,

    02

    mov dl,

    07h

    int 21h

    int 20h

    ret

    lang="matlab"

    % Test

    variable1 = 2;variable2 = 4;

    variable3 = 8;

    fprintf('v1: %f, v2: %f, v3: %f\n', variable1,

    variable2, variable3);

    fprintf(['This is a long string that',...

    ' will have to be split!',...

    ' Here are the variables: ',...

    ' variable1: %f, variable2: %f,',...' variable3: %f\n\n'], variable1,...

    variable2, variable3);

    HusniJanuary 2011

    Posts: 3,255

    Skatel_Linux_com said:

    untuk C++ dan C# belum highlight tuh. :D langnya diisi apa? "ceples-ples" kah?"cesarap" kah?

    http://diskusiweb.com/profile/3197/Husnihttp://diskusiweb.com/discussion/comment/236792#Comment_236792http://diskusiweb.com/profile/Skatel_Linux_comhttp://diskusiweb.com/profile/3197/Husnihttp://diskusiweb.com/profile/3197/Husnihttp://diskusiweb.com/discussion/comment/236792#Comment_236792http://diskusiweb.com/profile/Skatel_Linux_com
  • 8/2/2019 Salman Posting

    10/22

    atau ini diskriminasi syntax highlight dalam bahasa pemrograman. [-(

    yang C udah bisa, entah bener apa ngga. :D

    coba liat kodingan di atas om :D

    n1coliusJanuary 2011

    Posts: 6

    bro, kalau coding kita yg di tag

    itu panjang ke kanan kok tidak ada scrollnya ya?

    n1coliusJanuary 2011

    Posts: 6

    kang admin, itu tag codenya masih kepotong yak kalau kodingnya memanjang ke

    kanan gitu? apa gak lebih baik dikasih ada scrollnya? :)

    loubattJanuary 2011

    Posts: 2

    Ane malah ga bisa enter..... -_-'

    xyzzyJanuary 2011

    Posts: 1

    coba ah

    #include

    const char *s =

    "abcdefghijklmnopqrstuvwxyz";

    int main (void)

    {

    return(printf("%s\n", s) && *s++ &&

    main());

    http://diskusiweb.com/profile/3945/n1coliushttp://diskusiweb.com/discussion/comment/236879#Comment_236879http://diskusiweb.com/profile/3945/n1coliushttp://diskusiweb.com/discussion/comment/237015#Comment_237015http://diskusiweb.com/profile/27438/loubatthttp://diskusiweb.com/discussion/comment/237017#Comment_237017http://diskusiweb.com/profile/28320/xyzzyhttp://diskusiweb.com/discussion/comment/237242#Comment_237242http://diskusiweb.com/profile/28320/xyzzyhttp://diskusiweb.com/profile/27438/loubatthttp://diskusiweb.com/profile/3945/n1coliushttp://diskusiweb.com/profile/3945/n1coliushttp://diskusiweb.com/profile/3945/n1coliushttp://diskusiweb.com/discussion/comment/236879#Comment_236879http://diskusiweb.com/profile/3945/n1coliushttp://diskusiweb.com/discussion/comment/237015#Comment_237015http://diskusiweb.com/profile/27438/loubatthttp://diskusiweb.com/discussion/comment/237017#Comment_237017http://diskusiweb.com/profile/28320/xyzzyhttp://diskusiweb.com/discussion/comment/237242#Comment_237242
  • 8/2/2019 Salman Posting

    11/22

    }

    syuaaFebruary 2011

    Posts: 199

    Nah, trus klo mo insert images pake code apa tah?

    adminFebruary 2011

    Posts: 643

    ya pake img src aja bisa

    fanjavaakhmadFebruary 2011

    Posts: 23

    saunaartcreativityFebruary 2011

    Posts: 57

    LOCAL