Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. This is not a programming question... ;)

This is not a programming question... ;)

Scheduled Pinned Locked Moved The Lounge
questionc++
38 Posts 15 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • V Vikram A Punathambekar

    Ravish wrote: pls define a programmer for me Simple...VB users are not programmers. But that's just my 2 cents. Like I said, I'm just a student and my statements are largely based on my personal experiences with my fellow-blokes* , which admittedly isn't much. If I find the truth to be otherwise, I'll change my mind-it's open. * - Those fellows can't even write a program to swap two numbers without using a third varible in C. Neither can they write a function to swap two variables. And they've finished THREE years in BE CSE, at a college that's supposed to be very good. Like I said, my experience isn't much...so I might be wrong. Vikram. ----------------------------- 1. Don't ask unnecessary questions. You know what I mean? 2. Avoid redundancy at all costs. 3. Avoid redundancy at all costs. "Do not give redundant error messages again and again." - A classmate of mine, while giving a class talk on error detection in compiler design.

    R Offline
    R Offline
    Ravish
    wrote on last edited by
    #29

    Vikram Punathambekar wrote: Those fellows can't even write a program to swap two numbers without using a third varible in C. Neither can they write a function to swap two variables. It is more a reflection of those fellows intellect. The truth is in all my projects I never wrote any funda algo or swap two numbers etc. No linked list nothing. Just lots of straight forward if/ else constructs , switch case, DB access code. Truth is VB being a RAD (Remove Analysis and Design) tool doesnot encourage people to learn how stuff works. So you find lot of ignorant people who can do VB and they are not VB programmers just as people who can use printf function are not C programmers. Common refrain among IT managers is systems developed in VB is easy to maintain .Reason being you can easily find people who know VB. Truth is any medium sized VB project is very difficult(even difficult than C++) to maintain unless the original team were a very disciplined lot. On a side note, I am currently in Chennai. But did my Eng at GCT CBE .

    V 1 Reply Last reply
    0
    • L Liam OHagan

      Why is it so hard to find out technical details of visual basic related material? I ask this because of the following: I've got some software to test here at work, it's written in VB X| :( I needed to find out the maximum capacity of the int and long data types, knowing that they were probably different to the C++ ones I'm used to (and they are I eventually discovered) Using google to search for '+"visual basic" +long +"data type" maximum capacity size' returned nothing of any use Thought about it for a bit and used google to search for the following '+"visual basic" how big can a long be" and bingo! :rolleyes: Is it a reflection of the perception of VB programmers that they must be protected from knowing the underlying structure of the language? I haven't got a witty signature.... :((

      J Offline
      J Offline
      John Honan
      wrote on last edited by
      #30

      The age old, and overhyped debate about VB versus <insert another language here> resurfaces yet again. Why do people insist on bringing this up, when there is no right or wrong answer to what is best? - It's like saying 'which is better, red or blue?' From a software design and engineering perspective, the choice of language is determined by the requirements of the application (e.g. you wouldn't use VB for an embedded application in a mobile phone) From a project management perspective the choice of language is determined by: 1) the existing skill base and headcount, 2) deadlines and timescales. If you have an office full of VB developers and need an app developed in 6 months, you're not going to specify 'C++' as the development tool. Take a look at the contract job market out there; All the large companies who are developing database front-ends are doing so in VB because it's the best tool for the job. All the companies who are developing 3D graphics engines are doing so in C++ because it's the best tool for the job. Comparing VB to C++/Delphi/C# is a no-win argument. VB is a valid a programming language as any other out there, it's in widespread use. And like any language a lot depends on the skill level of the developer. Just as it's possible to write bad code in VB, it's equally possible to write bad code in C++. John. www.silveronion.com[^]

      1 Reply Last reply
      0
      • R Ravish

        Vikram Punathambekar wrote: Those fellows can't even write a program to swap two numbers without using a third varible in C. Neither can they write a function to swap two variables. It is more a reflection of those fellows intellect. The truth is in all my projects I never wrote any funda algo or swap two numbers etc. No linked list nothing. Just lots of straight forward if/ else constructs , switch case, DB access code. Truth is VB being a RAD (Remove Analysis and Design) tool doesnot encourage people to learn how stuff works. So you find lot of ignorant people who can do VB and they are not VB programmers just as people who can use printf function are not C programmers. Common refrain among IT managers is systems developed in VB is easy to maintain .Reason being you can easily find people who know VB. Truth is any medium sized VB project is very difficult(even difficult than C++) to maintain unless the original team were a very disciplined lot. On a side note, I am currently in Chennai. But did my Eng at GCT CBE .

        V Offline
        V Offline
        Vikram A Punathambekar
        wrote on last edited by
        #31

        Ravish wrote: It is more a reflection of those fellows intellect. Possible. Like I said, I'm kinda raw. Ravish wrote: Truth is VB does not encourage people to learn how stuff works. But programmers should know how things work. Ravish wrote: people who can use printf function are not C programmers. LOL. Agreed. Ravish wrote: Truth is any medium sized VB project is very difficult(even difficult than C++) to maintain you're actually speaking against VB now. Ravish wrote: I am currently in Chennai Where in Madras? Ravish wrote: did my Eng at GCT CBE Always nice to meet a fellow Coimbatorean :rose: . I'm studyin' at KCT, but I'm now in B'lore for internship. Vikram. ----------------------------- 1. Don't ask unnecessary questions. You know what I mean? 2. Avoid redundancy at all costs. 3. Avoid redundancy at all costs. "Do not give redundant error messages again and again." - A classmate of mine, while giving a class talk on error detection in compiler design.

        1 Reply Last reply
        0
        • R Rohit Sinha

          Venkatraman wrote: You ask most of the VB developers in india, i am sure you will be surprised to see their competence in the language. Er, I have a slightly (only slightly) different experience. I was surprised too. But not in the same way that you were probably talking about. :)
          Regards,

          Rohit Sinha

          Do not wait for leaders; do it alone, person to person.
          - Mother Teresa

          V Offline
          V Offline
          Vikram A Punathambekar
          wrote on last edited by
          #32

          Reference:i am sure you will be surprised to see their competence in the language Rohit  Sinha wrote: I have a slightly (only slightly) different experience Would that slight difference be by any chance an "in" before the word competence? ;P Vikram. ----------------------------- 1. Don't ask unnecessary questions. You know what I mean? 2. Avoid redundancy at all costs. 3. Avoid redundancy at all costs. "Do not give redundant error messages again and again." - A classmate of mine, while giving a class talk on error detection in compiler design.

          1 Reply Last reply
          0
          • V Vikram A Punathambekar

            Ravish wrote: pls define a programmer for me Simple...VB users are not programmers. But that's just my 2 cents. Like I said, I'm just a student and my statements are largely based on my personal experiences with my fellow-blokes* , which admittedly isn't much. If I find the truth to be otherwise, I'll change my mind-it's open. * - Those fellows can't even write a program to swap two numbers without using a third varible in C. Neither can they write a function to swap two variables. And they've finished THREE years in BE CSE, at a college that's supposed to be very good. Like I said, my experience isn't much...so I might be wrong. Vikram. ----------------------------- 1. Don't ask unnecessary questions. You know what I mean? 2. Avoid redundancy at all costs. 3. Avoid redundancy at all costs. "Do not give redundant error messages again and again." - A classmate of mine, while giving a class talk on error detection in compiler design.

            B Offline
            B Offline
            brianwelsch
            wrote on last edited by
            #33

            Vikram Punathambekar wrote: Those fellows can't even write a program to swap two numbers without using a third varible in C I can't immediately think of a way either. But , errr.. . so what!! . Get off your high horse, Vikram. I'm sure each one of them is infinitely better than you at something, just like you may be better than they are at swapping variables in C. ;) BW "I always wanted to be somebody, but now I realize I should have been more specific." - Lily Tomlin

            V 1 Reply Last reply
            0
            • B brianwelsch

              Vikram Punathambekar wrote: Those fellows can't even write a program to swap two numbers without using a third varible in C I can't immediately think of a way either. But , errr.. . so what!! . Get off your high horse, Vikram. I'm sure each one of them is infinitely better than you at something, just like you may be better than they are at swapping variables in C. ;) BW "I always wanted to be somebody, but now I realize I should have been more specific." - Lily Tomlin

              V Offline
              V Offline
              Vikram A Punathambekar
              wrote on last edited by
              #34

              brianwelsch wrote: Get off your high horse :wtf: ? I'm sitting on a chair. You been drinking too much? ;P Ok, joking apart, I agree that swapping two numbers without using a third varible in C isn't the ultimate test for proficiency. brianwelsch wrote: I'm sure each one of them is infinitely better than you at something Undoubtedly. They have a life, which I don't. :-O . No, I wasn't bragging...just the heat of the moment. brianwelsch wrote: I can't immediately think of a way either. Here's one:

              #include <iostream>
              using namespace std;
              int main()
              {
              int x=5,y=7;
              cout<

              In fact, you can replace ^ with any commutative operator, like + and * .

              Vikram.


              1. Don't ask unnecessary questions. You know what I mean?
              2. Avoid redundancy at all costs.
              3. Avoid redundancy at all costs.

              "Do not give redundant error messages again and again." - A classmate of mine, while giving a class talk on error detection in compiler design.

              B J 2 Replies Last reply
              0
              • V Vikram A Punathambekar

                brianwelsch wrote: Get off your high horse :wtf: ? I'm sitting on a chair. You been drinking too much? ;P Ok, joking apart, I agree that swapping two numbers without using a third varible in C isn't the ultimate test for proficiency. brianwelsch wrote: I'm sure each one of them is infinitely better than you at something Undoubtedly. They have a life, which I don't. :-O . No, I wasn't bragging...just the heat of the moment. brianwelsch wrote: I can't immediately think of a way either. Here's one:

                #include <iostream>
                using namespace std;
                int main()
                {
                int x=5,y=7;
                cout<

                In fact, you can replace ^ with any commutative operator, like + and * .

                Vikram.


                1. Don't ask unnecessary questions. You know what I mean?
                2. Avoid redundancy at all costs.
                3. Avoid redundancy at all costs.

                "Do not give redundant error messages again and again." - A classmate of mine, while giving a class talk on error detection in compiler design.

                B Offline
                B Offline
                brianwelsch
                wrote on last edited by
                #35

                Vikram Punathambekar wrote: Here's one: just figured this one out, too...

                x = 5 ; y = 7

                x = x + y 5 + 7 = 12
                y = y - x 7 - 12 = -5
                x = X + y 12 + (-5) = 7
                y = y * (-1) (-5) * (-1) = 5

                :) BW "I always wanted to be somebody, but now I realize I should have been more specific." - Lily Tomlin

                V 1 Reply Last reply
                0
                • V Vikram A Punathambekar

                  brianwelsch wrote: Get off your high horse :wtf: ? I'm sitting on a chair. You been drinking too much? ;P Ok, joking apart, I agree that swapping two numbers without using a third varible in C isn't the ultimate test for proficiency. brianwelsch wrote: I'm sure each one of them is infinitely better than you at something Undoubtedly. They have a life, which I don't. :-O . No, I wasn't bragging...just the heat of the moment. brianwelsch wrote: I can't immediately think of a way either. Here's one:

                  #include <iostream>
                  using namespace std;
                  int main()
                  {
                  int x=5,y=7;
                  cout<

                  In fact, you can replace ^ with any commutative operator, like + and * .

                  Vikram.


                  1. Don't ask unnecessary questions. You know what I mean?
                  2. Avoid redundancy at all costs.
                  3. Avoid redundancy at all costs.

                  "Do not give redundant error messages again and again." - A classmate of mine, while giving a class talk on error detection in compiler design.

                  J Offline
                  J Offline
                  Joe Woodbury
                  wrote on last edited by
                  #36

                  You do know this method is slower than using an intermediate variable. Has been since I first heard of it ten years ago.

                  V 1 Reply Last reply
                  0
                  • B brianwelsch

                    Vikram Punathambekar wrote: Here's one: just figured this one out, too...

                    x = 5 ; y = 7

                    x = x + y 5 + 7 = 12
                    y = y - x 7 - 12 = -5
                    x = X + y 12 + (-5) = 7
                    y = y * (-1) (-5) * (-1) = 5

                    :) BW "I always wanted to be somebody, but now I realize I should have been more specific." - Lily Tomlin

                    V Offline
                    V Offline
                    Vikram A Punathambekar
                    wrote on last edited by
                    #37

                    In fact, you can use * and / instead of + and -. At first, I used to use + and - . Then I found the bitwise OR ( ^ ) was better and more elegant- you need to use only a single operator, and moreover, while everybody knows what + and - do, not everyone knows what ^ does. Yes, I kinda like being different, though I don't know if it's something to be proud of. :-O Cheers, Vikram. ----------------------------- 1. Don't ask unnecessary questions. You know what I mean? 2. Avoid redundancy at all costs. 3. Avoid redundancy at all costs. "Do not give redundant error messages again and again." - A classmate of mine, while giving a class talk on error detection in compiler design.

                    1 Reply Last reply
                    0
                    • J Joe Woodbury

                      You do know this method is slower than using an intermediate variable. Has been since I first heard of it ten years ago.

                      V Offline
                      V Offline
                      Vikram A Punathambekar
                      wrote on last edited by
                      #38

                      Joe Woodbury wrote: this method is slower Oh, I didn't know that- never actually tested it. Thx. But then, the question was not to swap two numbers in the least time, but to do it without using a third variable. For all practical purposes, I use a temp variable. It's just that there's more than one way to do it. Vikram. ----------------------------- 1. Don't ask unnecessary questions. You know what I mean? 2. Avoid redundancy at all costs. 3. Avoid redundancy at all costs. "Do not give redundant error messages again and again." - A classmate of mine, while giving a class talk on error detection in compiler design.

                      1 Reply Last reply
                      0
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                      • Login

                      • Don't have an account? Register

                      • Login or register to search.
                      • First post
                        Last post
                      0
                      • Categories
                      • Recent
                      • Tags
                      • Popular
                      • World
                      • Users
                      • Groups