1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

What's the best programming language for BOT coding?

Discussion in 'General Programming Chat' started by indianbill007, May 23, 2010.

  1. indianbill007

    indianbill007 Jr. VIP Jr. VIP

    Joined:
    Jan 8, 2010
    Messages:
    4,813
    Likes Received:
    4,051
    Occupation:
    Making Money when the world is sleeping
    Location:
    Menlo Park - Next to Zuck
    Which language do you recommend to develop bots.

    1. C#

    2. VB (classic)

    3. Python

    4. Perl

    5. Delphi

    Please suggest based on your coding experience.
     
  2. smack

    smack Junior Member

    Joined:
    Feb 1, 2010
    Messages:
    182
    Likes Received:
    78
    Occupation:
    Software Engineer/Evil Genius
    Location:
    inside .NET
    i don't recommend classic VB for anything these days. it had its purpose as a rapid development platform a few years ago, but now with the abilities of VB.NET it really doesn't have a use.

    my vote goes for VB.NET or C#. these both give you the power and flexibility of a true OOP with the rapid development potential of two high level languages built on a robust framework.

    now i can't speak specifically on Python, Perl, or Delphi since i don't work with them, but i always like to steer newer developers to .NET for many reasons. here are a few of them:

    1.) as stated before, true OOP power built on a robust framework
    2.) the ability to create windows, web, and mobile applications in the same language
    3.) a massive community with loads of knowledge easily accessible through google
    4.) excellent framework components geared towards allowing applications to interact with the internet such as HTTPWebRequest and the System.Sockets namespace

    a huge consideration for bot design though is what you have experience with. if you have some intrinsic knowledge of any of those other languages then you may want to start there. good bots require good code, but by definition also need quick turn around time. thing change quickly in this industry, being able to properly adjust and respond is a huge asset to any developer.
     
  3. ericsson

    ericsson Elite Member Premium Member

    Joined:
    Apr 25, 2009
    Messages:
    2,642
    Likes Received:
    8,132
    Occupation:
    www
    Location:
    Swe
    Home Page:
    Do as YT does it.. Python :)

    Or c# .. very fast..
     
  4. zestoi

    zestoi Newbie

    Joined:
    Mar 9, 2010
    Messages:
    41
    Likes Received:
    3
    all really depends what the bot will be doing. if processing websites/text then generally its a no brainer as perl is the king of that. also ideal for fast prototyping.

    if you want out and out performance then C or only slightly slower would be C++ or C#.

    regarding "flexbility and power" of OOP - most OO (C++) projects i've had to work on have shown that not to be true. but if you like OO then it's not a bad way of working - depends on exactly what you want to do of course. OO in perl is very good if you use 'Moose' (checkout CPAN for that).

    the only seriously well designed OO language is smalltalk and i wouldnt ever use that to code a bot lol.
     
  5. voyevoda

    voyevoda Regular Member Premium Member

    Joined:
    Mar 21, 2010
    Messages:
    217
    Likes Received:
    97
    Location:
    Eastern Front
    Ruby.

    Net::HTTP + WWW::Mechanize + Nokogiri = a lot done in not a lot of code.

    Trivial to multithread, too. :)


    Ruby is heavily inspired by Smalltalk. Anything that needs performance is done in raw C extensions.
     
  6. Bartholomew

    Bartholomew Regular Member

    Joined:
    Dec 31, 2009
    Messages:
    290
    Likes Received:
    103
    Home Page:
    I know all these languages but Basic, and I strongly recommend Python for bots. Python is (1) dynamic, (2) has lots of libraries related to http, (3) programs writen in python are readable and short, (4) supports OOP, functional, declarative, procedural styles, (5) the programs will work on almost every OS you can imagine.
    There are a few flaws in it tho. It's the slowest of the lot, it doesn't work with threads well (but as you're going to write bots, your threads will be in IO waiting state most of the time, so you won't see the difference).

    >C#
    Requires to write a lot of boilerplate code. Its' static typing is good for corporate development, but for bots I'd choose something other. You might choose c# tho if you need bots with GUI.
    Also pure OOP is overrated shit. C# 3.5 goes in the right way with LINQ and expressions, but still it is not enough flexible for personal use. IMHO.

    >VB (classic)
    Legacy language, Delphi is better in every perspective but the price.

    >4. Perl
    Python can do everything Perl does, but easier. Perl language often produces "write-only" apps. The advantage of perl (and even more of php) is that it is supported by default on almost any hosting, even free one. Lots of scripts already done in perl, so you will have lots of working examples. It's usually slightly faster than python.

    >Delphi
    Inferior to C#. You might use Delphi if you need unmanaged GUI app, which does not require .Net framework, as it is usually easier to do this in Delphi than in C++. It will probably produce the fastest code of the lot, but if you're really after speed, I'd recommend C++ or pure C.
     
  7. sumax

    sumax Junior Member

    Joined:
    Jun 25, 2009
    Messages:
    179
    Likes Received:
    54
    Occupation:
    Programmer
    Location:
    /web/developer
    i vote for : python, java and c
     
  8. Bartholomew

    Bartholomew Regular Member

    Joined:
    Dec 31, 2009
    Messages:
    290
    Likes Received:
    103
    Home Page:
    Java
    Code:
    [FONT=monospace]
    [/FONT]class HelloWorldApp {
        public static void main(String[] args) {
            System.out.println("Hello World!"); 
        }
    }
    
    
    Python
    Code:
    print "Hello World!"
    
    That's why I hate Java ;)
     
    • Thanks Thanks x 1
  9. kaidoristm

    kaidoristm Power Member

    Joined:
    Feb 13, 2009
    Messages:
    561
    Likes Received:
    726
    Occupation:
    Freelancer
    Location:
    Estonia
    Home Page:
    php for all the stuff
     
  10. GeoffreyF67

    GeoffreyF67 Guest

    Lisp FTW :eek:

    G-Man
     
  11. elbeto

    elbeto Registered Member

    Joined:
    May 1, 2009
    Messages:
    98
    Likes Received:
    75
    Occupation:
    Beer drinker
    Location:
    close to the laptop
  12. djelica

    djelica Junior Member

    Joined:
    Jun 26, 2009
    Messages:
    151
    Likes Received:
    60
    Sorry for posting question in this thread but i wouldn't like to start new thread just because of one question which is related to OP's...

    I want to build program mainly for FB automation, i would try to add some features like add friends, send suggestions and similar stuff. But the problem is, i have only basic knowledge in programming, to be exact, only basic Java programming.

    I am currently learning Java in my college and i want to expand my skills a little bit. I would like to set mentioned program as my target, and learn while building it.

    Is it achieveable using Java ?

    Suggestions apperciated
     
  13. zestoi

    zestoi Newbie

    Joined:
    Mar 9, 2010
    Messages:
    41
    Likes Received:
    3
    nice post there - but i wouldn't choose php. sure it can get the job done, but not as nicely/cleanly as many other languages. php was a hack from day 1 and they haven't gone back for a redesign. having said that if you mostly/only code in php then that makes php your best choice i suppose. most of my web coding these days is done in php - not because its a good language but because most people can easily get php hosting.

    re: ruby+python... i forgot to mention these two, mostly because i don't use them very much or rather can't code in them well enough yet. from what i've seen though both are very rich and well designed languages. learning at least python is on my todo list when i have some time lol.

    re: facebook+java... personally i stay away from java whenever possible. i've only spent maybe 4 years being forced to code java and that was because they paid me enough not because i liked the language :eek: a quick google did show up a facebook api hosted on code.google so i'd suggest checking it out. i'm sure it's possible - but you can also guarantee it's going to take at least as three times as much code as in any other language (php included).

    btw... not meant to be an attack on php... it is what it is... and i have to code a lot of php these days. it gets the job done and gets me paid, which at the end of the day is the main thing... :D
     
  14. Tanksapka

    Tanksapka Registered Member

    Joined:
    May 7, 2010
    Messages:
    98
    Likes Received:
    12
    "Which language do you recommend to develop bots?"

    you have 2 choice: python or php these are the fastest and most productive langugaes to wrinting bots.

    php originaly designed to web so that's why php is a little more porductive than python however you can find easily good python librarys. but i guess the best is php + javascript+ curl +simple_html_dom
     
  15. kaidoristm

    kaidoristm Power Member

    Joined:
    Feb 13, 2009
    Messages:
    561
    Likes Received:
    726
    Occupation:
    Freelancer
    Location:
    Estonia
    Home Page:
    No worries :)
    Now to protect php a bit i must say
    If i have to choose between php and C# i would go with php.
    Php is damn big it's not only variables and arrays. You can combine it without a problem with C .
    You can build GUI applications with it much faster and easier than any other language. It's not limited to work only on server. You can compile entire php into one 2mb library and run it without any server or browser with nice GUI interface.
     
  16. Cloaks

    Cloaks Regular Member

    Joined:
    Mar 20, 2010
    Messages:
    298
    Likes Received:
    90
    I'd go with Java any day. It's designed for applets and therefore it's easy to work with connections, sockets etc.. It's easy to learn, powerful, can be hosted online, etc.
    But if you don't want to get into it a lot, go for Python!
     
  17. frankeh

    frankeh Newbie

    Joined:
    Apr 13, 2010
    Messages:
    36
    Likes Received:
    8
    I use PHP because it's easy to learn, there's tons of examples and tutorials out there and you can host it anywhere.

    Lack of multitasking is a problem for sure. Really is slowing down my web crawling ability.
     
  18. bobski

    bobski Registered Member

    Joined:
    Jun 7, 2009
    Messages:
    54
    Likes Received:
    22
    FYI, you can now use Python and Ruby in .NET ...so you can get the best of all worlds (in theory!) I'm just starting to try Ironpython

    Code:
    http://ironpython.net/
    
    http://ironruby.net/
    I think you can also "mix-n-match" with other .NET languages, like C#. So you should be able to use c# modules alongside Python/Ruby modules in the same app. But as I said, I'm only just starting to play with Ironpython, so I may not have understood correctly

    HTH
     
  19. kaidoristm

    kaidoristm Power Member

    Joined:
    Feb 13, 2009
    Messages:
    561
    Likes Received:
    726
    Occupation:
    Freelancer
    Location:
    Estonia
    Home Page:
    Multitasking is not problem at all with php your only limited by your hosting.
     
  20. frankeh

    frankeh Newbie

    Joined:
    Apr 13, 2010
    Messages:
    36
    Likes Received:
    8
    I host at home.
    PHP has no native multithreading ability.

    I'm assuming you mean running multiple CLI instances of php at the same time?

    If not, please go into more detail. It's driving me mad.