Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Other Programming > Other Programming Languages
| Search | Today's Posts | Mark Forums Read
Other Programming Languages If you have a coding issue to discuss about another language that really isn't provided for in any other forum here (not ASP.NET C#, C++, VB, PHP, JavaScript, Python, Java, Perl, Applescript, XML or any of the other forum topics we have), post it here. Enough discussion on a language we don't have covered could prompt a new forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Other Programming Languages section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
  #1 (permalink)  
Old May 24th, 2007, 01:51 AM
Registered User
 
Join Date: May 2007
Location: New Delhi, Delhi, India.
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Declaration of variable without initialization

Why does the declaration "int i;" generates value of i as 0 in languages like Java and C# but displays garbage values in C and C++. Also, when we declare i outside main in C or declare it as static outside class it shows value 0. Why is it so?



Reply With Quote




Similar Threads
Thread Thread Starter Forum Replies Last Post
i get error during declaration of variable srivastavaavivek Forum and Wrox.com Feedback 1 March 12th, 2007 09:42 AM
Doubt regarding variable declaration and useage dsekar_nat XSLT 2 July 27th, 2006 10:19 PM
variable initialization vin_0x1 Classic ASP Databases 1 April 18th, 2006 06:46 AM
asp variable declaration bad characters crmpicco Classic ASP Basics 2 August 18th, 2005 07:49 AM
variable initialization with try..finally guppyheart C# 7 July 17th, 2003 06:47 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.