Cutegentility's Posts
Nairaland Forum › Cutegentility's Profile › Cutegentility's Posts
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 (of 17 pages)
. |
. |
. |
Greeting to everybody in the house. I hope to continue with this thread sooner. Thanks for the support. |
Nice one |
See competition o |
Snwokenk:OK, nice one. I love programming. |
Snwokenk:Waoh, I am glad to hear this, I am having many project to accomplish with python. What framework do you use? |
Data types is categorised into two, immutable and mutable. There are six data types in Python, they are: numbers, strings, tuples, lists, dictionaries and lastly, sets. Immutable character are character whose value once assigned cannot be altered. Examples are numbers, strings and tuples while the rest are mutable. |
The identity operator is nothing to worry about, it is use to check the value if it is either true or false in a program The last operator which is the membership set deals basically with list. It is a set of item. Note, the list identifier is to be written in capital letter Z = [a, b, c , d] We shall be dealing with this under the various data types. |
Bitwise Operators operate on bit level. This convert your data to binary and carry out the output. e.g 1110 1010 We have the biwise And denoted by the symbol & Bitwise denoted by vertical slash |, And bitwise Xor denoted by ^. For bitwise and 1110 1010 1010 Bitwise or 1110 1010 1110 Bitwise xor 1110 1010 0100 There are left shift and right shift in bitwise operation. 1100 >> 2 becomes 0011 1100<<2 becomes 0000 |
Logical operator. We have the and, or and the not gate. In this case, you will be working on true and false. Nb: always type true as True and false as False in Python. Because it is a reserved keyword. a = True b = False For the And gate: The output is high (1) if both the inputs are high otherwise low (0). Remember we are working on binary. So, the output of and gate is always low. 1 and 0 = 0 0 and 1 = 0 1 and 1 = 1 0 and 0 = 0 For the or gate: The output is low(0) if both the inputs are low otherwise high (1). So, the output of or gate is always low. 1 or 0 = 1 0 or 1 = 1 1 or 1 = 1 0 or0 =0 The not gate is a reversal of the logic gate. If the inputs are high, the output will be low. |
Comparison Operators This is use to compare the values of a given variables. We use operation < Less than > Greater than == Equivalent to != not equivalent to == is used instead of one equivalent sign in comparison operator The value for this is either true or false. Take for instance, print("is Z greater than Y", Z >Y) |
Then the assignment operator assign the value of the right side as the value of the left hand side. say Z = X + Y Z = 150. Now, the assignment operator is useful when dealing with two variables. Hence, for addition of Z and Y. You simply use the shorthand += Hence, Z +=Y Z//=Y, Z/=Y, |
You execute your operation by using the print statement. print("",). Take: X = 50 Y= 100 To carry out arithmetical operation, use start by typing: print("X plus Y," X+Y) print("X minus Y," X-Y) print("X divided by Y," X/Y) print("X multiply by Y," X*Y) For exponential you use double asterisk Say 10 raise to power 2 print(10^2, 10**3) For modulus division. Modulus division is just the remainder of your division. The modulus of 9 divided by 2 is 1. So, print("9 modulus 2", 9%2) Then // for floor division. It simply round off your decimal to zero. Say 20//3 equals to 9 or say 9.0 |
Humchi:well done job, I was so busy. |
God bless those doctors. |
GreatAchiever1:I haven't find yet, everyone will keep trying. |
olamil34:Waoh, nice one. I never knew nairaland use this. Amazing |
sparkle6:You may try the zip file |
sparkle6:what version? I also encounter same problem. |
Darivie04:So true, it depends on individual and their learning skills. But, the reason why I sometimes support videos is that, if one is a self-taught programmer. There are some words that you may not know the pronunciation. Take for instance operation // for flow division. Well it may also depend on how comprehensive the PDF document is. |
sparkle6:download xampp, I think it has in built mySql |
Now, for the Arithmetical Operator. You use Mathematical symbols. +, -,/,* (addition, subtraction, division and multiplication) ** for exponential // for flow division and % for modulus division |
youngds:OK, nice one bruh. I support PHP for web development any day any time. Only that Python is a beginner language. |
TimmyBrass:Alright, have you installed the Python software. |
youngds:Yeah, I find out that Python is a very vast programming language. It is used across many domains for data science, artificial intelligence, machine learning,GUI and the likes. I think Django and flask are Python framework for developing websites. |
Please, for complete beginner. There are two version of python which are version 2.7 and version 3.6. It is advisable to download the version 3.6 because of its features, version 2.7 is just for those industries that are already using this version. Aside this, installing Python software is not enough without installing Python IDE. IDE is an abbreviation of Integrated Development Environment which enable one to work on multiple project. For me, I use the community version of pycharm as the professional version is a paid one. |
gracefoundmme:They are: 1. Arithmetical Operators 2. Assignment Operators 3. Comparison Operators 4. Logical Operators 5. Bitwise Operators 6. Identity Operators and lastly 7. Membership operators |