阿哥论坛

 找回密码
 立即注册

QQ登录

只需一步,快速开始

新浪微博账号登陆

只需一步,快速开始

搜索
查看: 1496|回复: 1

《C#高级编程》 读书心得1--核心C# 几点你可能没注意,但很基础的小东西。

[复制链接]

6

主题

0

好友

22

积分

IT工程师

Rank: 1

升级  44%

发表于 2013-1-1 22:09:21 |显示全部楼层
《C#高级编程》 读书心得1--核心C# 几点你可能没注意,但很基础的小东西。

<div class="postbody"><div id="cnblogs_post_body">这是本系列读书心得第一篇。
其实所谓核心C#也就是C#的语法基础,相信大家应该已经非常熟悉了,在这里说一下在书中看到,大家可能平时没有太注意到的。此篇比较基础,也是第一次写读书心得,请勿喷啊。
变量以及其作用域。
     首先声明变量:可以直接用int i; 其实它是声明一个名为i 的System.Int32的一个实例。 像int, long这样的关键字都是指向.net预定义类型,也就是说用他们声明的变量是他们所指向的.NET预定义类型的一个实例。在.net中一共有15个这样的预定义类型,13个值类型,2个引用类型(object和string)。如int 对应的System.Int32, long对应System.Int64。 就像大学的时候我们C语言的老师一直都说int变量的值范围为-32768~32767,是因为当时的C语言编译环境为16位。 还要强调一点就是string字符串在C#中为引用类型,也就是说一个string变量是存储在托管堆上的,而像int这样的值类型是存储在堆栈上。
    我们在int上按F12跳转到定义就会看到它其实是一个结构体:public struct Int32, 所一它存储在堆栈上,而string的定义是public sealed class String是一个类。
    在定义一个string a后,并没有为其初始化a的值为null,而int a后a默认为0。 再有string a="123" 声明了一个string类型,然后对其再次赋值a="456",会再次创建一个值为456的实例,而不是修改值为123的实例。int a=9之后int b=a 这样在内存中会生成两个值为9的int结构体实例在堆栈中。还有bool变量只接受true或者false,而不会接受0或者1不会对其隐式类型转换。bool变量的默认值为false。
    关于int对应System.Int32,bool对应System.Boolean等其实都是结构,他们都是继承于System.ValueType, 而System.VauleType又继承与System.Object. 所以他们的实例都可以进行ToString()这样的操作。String就直接继承与System.object。
    关于变量的作用域有这样一个有趣的事,请看下面两段代码
<div class="cnblogs_code"> 1     class Program1 2     { 3         private static void Main(string[] args) 4         { 5             int j = 20; 6             for (int i = 0; i < 10; i++) 7             { 8                 int j = 30; 9                 Console.WriteLine(j + 1);10             }11         }12     }

0

主题

0

好友

6

积分

IT工程师

Rank: 1

升级  12%

发表于 2013-3-6 15:24:38 |显示全部楼层

The hair derives its nourishment from the rind

by Dorothy Yamich
by Meghjeet Sagaciti
The fundamental matter about hair care tips
by Abdullah
About Author
Other Related Articles

by Meghjeet Sagaciti
Author: Meghjeet SagacitiArticle Tools:The hair derives its nourishment from the rind, the glands around as easily as in the follicle. Hair requires sebum and some extent of moisture. The general concept that applying oil in the chief causes hair increase is still to be proven. The almost significant points to be noted in hair care are cleanliness, scalp hygiene, haircut and tone. Your character of hair is the best circumstance element when it comes to hair care franklin marshall. As you may get noticed, not everyone has the same hair character. Some have thick hair, some have crude hair and others have brittle hair mercurial vapor. Naturally, hair care for each of these varies.
The leading trouble in the scalp is dandruff. It is characterized by light-colored flecks on the scalp and discomfort in the chief. Cosmetically and hygienically it is a good trouble and causes good soreness to an individual. Proper scalp hygiene and cleanliness helps in controlling dandruff. Additionally, antidandruff shampoos and scalp oils can assist hold dandruff in cheque. Choose a shampoo that has any of these antidandruff ingredients: coal tar distill, selenium sulfide, ketoconazole, salicylic acidic, zinc pyrithione, or sulfur. Tea tree oil contains ant fungal and sterile qualities that well cut the fungus establishment and moisturizes the hair. It is not recommended though to use tea tree oil immediately to the hair. Simply make 5 to 6 drops of it to your shampoo. Right next to a dandruff trouble is feeble hair and hair departure. The hair departure being talked about here is not the age related one. Rather, it is the abrupt hair departure caused by a switching in your hair care products. You must make sure that the cause of your hair loss is identified. Many medical treatments cause a side effect of hair loss monster beats. In such cases the conventional methods of preventing hair loss will have no effect.
The almost fundamental matter about hair care is to rinse the hair and scalp regularly with spotless tender water. Never rinse your hair with difficult water or exceedingly warm water abercrombie. Wash the hair initially by allowing water to wash it easily franklin marshall pas cher. Try lightly massaging your scalp as water runs through it. Make certain to use the shampoo that is better for your hair character mercurial. Ensure that the shampoo you take is of a dependable brand. Massage your scalp as you use shampoo. Then rinse the shampoo away and use conditioner to the hair. Let the conditioner drench for a few minutes before washing it away and again rinsing your hair. If your hair is arid or crude or brittle, there are several particular shampoos and conditioners ideal for you nike pas cher. There are too particular shampoos for dandruff. To forbid hair departure Monster Beats, here are some tips that could assist you moncler. First, never take overly more of hair drier as they can induce departure of hair. Never sweep your hair for a lengthy moment. Do not alter your hair creams shampoos or conditioners frequently chaussures louboutin.
Did you find this article useful? For more useful tips and hints, points to ponder and keep in mind, techniques, and insights pertaining to Internet Business, do please browse for more information at our websites.  hollister pas cher, www.100earningtips.com
Article Source:
Hair care has get a leading matter in beauty and it has by itself branched away as a specialty area. The hair is an appendage that grows out of the rind through the hair follicle. A hair maybe compared to a tree, as it has an origin seated in the follicle and it has a dense body forming its home and the shoot grows upward and out of the rind.

Related articles:

  
   Other Related Articles
  
   Auto replacement tops
  
   Online Art Gallery  A Striking Triangle Of Creativity, Trade And Technology For You Article - Arts And Entertainment Articles
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册 新浪微博账号登陆

回顶部