Tag:variable

  • Summary of variable learning in Ruby

    Time:2020-1-18

    There are several forms of variables in ruby, including local variables, instance variables, class variables, and global variables. For beginners, it’s easy to get confused, especially for those who do java like myself. After careful identification and learning, the differences and usage scenarios of these variables are summarized as follows: 1、 Naming method 1. Local […]

  • Value copy of common errors in golang and single variable explanation in for loop

    Time:2020-1-9

    Preface Golang (Chinese Name: go language) is the second open source programming language released by Google in 2009. Go language is specially optimized for the application programming of multiprocessor system. The program compiled by go can be as fast as C or C + + code, and it is more secure and supports parallel process.. […]

  • One of lebyte Java variables and data structures: Java programming specification, keyword and identifier

    Time:2019-11-24

    Hello, I’m lebyte’s Xiaole. This time, I’m going to bring you Java variables and data types. This article is the first episode: Java programming specifications, keywords and identifiers. I. programming specification The name of any place needs to know its meaning; Code indented appropriately Write process pair programming Comment code properly II. Key words 1), […]

  • Lebyte Java variables and data structure II: Java constants and variables

    Time:2019-11-23

    Hello everyone, Xiaole will tell you the basic knowledge of Java. Last time I talked about one of lebyte Java variables and data types: Java programming specifications, keywords and identifiers. This time I will go on to talk about Java constants and variables. 1, constant 1), definitionA quantity whose value does not change during the […]

  • Summary of variables in DOS batch file

    Time:2019-10-29

    The variables in batch processing can be divided into two categories: system variable and custom variable. System variable: Their values are automatically assigned by the system according to the pre-defined conditions, that is, these variable systems have defined values for them.We don’t need to assign values to him. We just need to call and list […]

  • Naming rules for variables, functions and classes

    Time:2019-10-6

    1, naming is worthy of the name.When naming, we must consider its display meaning and context, and do not think that it is a waste of time to spend on variable naming. Of course, if your program is very short, you don’t need to think so much about it. Just bury your head in writing […]

  • Is the python collection a variable summary

    Time:2019-9-28

    A set is an unordered variable sequence. The elements in a collection must be hash-able, that is, immutable data types. Empty set a=set() Note that a={} creates an empty dictionary. Set — Variable sets. Elements in a collection can be added or deleted dynamically. Frozenset — an immutable set. Elements in a collection are immutable. […]

  • Instance code for initialization of Perl constants, multidimensional arrays and variables

    Time:2019-8-20

    Example 1: Copy codeThe code is as follows: #!/usr/bin/perluse strict; use warnings;my $test = “asdf”;print “${test}_test2\n”;#constantuse constant {    AAA => “aaa”,    BBB=> “bbb”,    MIN_TOTAL => 12,    SCORE_PASS => 90,    SCORE_RED => 70,};print AAA;print SCORE_PASS;#two dimesion arraysmy @steps = (      [“aaa”, “aaavalue”],      [“bbb”,”bbbvalue”],      [“ccc”,”cccvalue”]);print “\n”;foreach my $i (0 .. $#steps){  print “$steps[$i][0]:$steps[$i][1]\n”;} Code 2: Copy codeThe […]

  • Perl uses variables as handles

    Time:2019-8-7

    Copy codeThe code is as follows: #!/usr/bin/perl -wuse strict;use warnings;use FileHandle;my %fh;my @array = (1..10);for(1..5){        open $fh{$_},”>$_.txt” or die;}for(1..5){# print $fh {$} “$__ n”; error        $fh{$_}->print( “$_\n” );# For functions in FileHandle (my $h = $fh {$}; print $h “$__ n”; } Note: The above errors are due to the fact that <> is not a […]

  • Linux Definition Variable Script Sharing

    Time:2019-8-5

    In this paper, we share Linux variable definition script for your reference. The details are as follows. There are two pieces of code that are basically the same, but the variables are changed, and the others are unchanged, but the results are different in the execution process. Code 1: vi back.sh #backup import file,such as […]

  • Do you really know the variables and types?

    Time:2019-7-7

    Guide reading Variables and types are learningJavaScriptThe first thing you come into contact with, but what seems to be the simplest thing often hides a lot of knowledge that you don’t understand or are prone to make mistakes, such as the following questions: JavaScriptWhat is the specific storage form of variables in memory? 0.1+0.2Why not […]

  • Go Language Learning Packages and Variables

    Time:2019-7-2

    Preface This paper mainly introduces the relevant contents about go language package and variables, and shares them for your reference and study. Let’s see the detailed introduction together. I. The Concept of Package Package is an indispensable part of go language. It is defined on the first line of each go source code in the […]