Sadaqat Academy provides free learning courses, scholarships, guidance, Test Preparations, videos lectures, past papers for all class.

No More Tension: All is here

Guidances, TimeTable, News etc.

Wednesday, April 20, 2022

Mobile Development - Lecture 5

 

Mobile Development- Using React Native - Lecture 5

Lecture Outcome:

At the end of the lecture, students will be able to know about

  • Programming Basis
  • HOW TO RUN A JS FILE WITHOUT ANY FRAMEWORK
  • HOW TO WRITE A FUNCTION 
  • FUNCTIONS 
# PROGRAMMING BASICS 

## Variables/Constants  ===> var / const 
## Functions ==> namedFunctions, anonymousFunction, CurriedFunctions
## Operators => assigners, conditional operators,
## LOOPERS => ak kam ko repeeat krna (loop/itteration) , (map, reduce, filter,for,while)


## PROGRAMMING STRUCTURE 
- FUNCTIONAL PROGRAMMING 💚
- OOP PROGRAMMING

## FUNCTIONS 

 - how to write/see/understand ( recognise a function )  



 ## CODE EDITOR VS IDES  #ASSIGNMENT  

 ## What is LOGING , WHAT IS A CONSOLE
    -> console is the hidden softwarea command runner
    -> LOGING -> write somthing 


# CODERS HATE WHITE SPACE so does the COMPUTER 
    -> javascript hyphen (Dash) -    sa b nafrat 
    -> _ (underscore) we kinda have love hate relationship



## TEMPLATING 
   {{YOUR_NAME}}




   ## TO REFRESH CONCPETS

   https://www.youtube.com/watch?v=PkZNo7MFNFg 



# HOW TO RUN A JS FILE WITHOUT ANY FRAMEWORK

make a new file and save it with an extention of `.js`

e.g.  `myFirstFile.js`

- go to your terminal/cmd/powershell
- cd to the folder where you saved the file
- call your NODE COMPILER TO HELP YOU COMPILE THE CODE
 e.g. `node myFirstFile.js` 


// HOW TO WRITE A FUNCTION 

function functionOne(){}

// init krna 
function functionTwo(x = 3){
    console.log(x);
}

// to run a function you have to call it   {{FUNCTION_NAME()}}

functionTwo()



// () anythin in it has to be used later 
// {} scoper ( scope/range )

## FUNCTIONS 

- () => props #properties #perks #parameters #arguments
- {} => scoping, structuring, 

-> function types
    => a funciton can be without props or with prop/s


<!-- non-prop function  -->
<!--  a function with no parameter is call non-parameter -->

function myFunction() {

}


<!-- proped/parameterd  function -->
<!-- asa function jo ak ya ak sa ziaada params -->

function myFunc(x,y,z){

}


<!-- returners function/pure function  -->
<!-- returners function is  a func whihc has a return at the end of its curly braces-->

function myReturner(){

    return;
}


function sum(x,y){
    return x+y
}
Share:

0 comments:

Post a Comment

Search This Blog

Blog Archive

Recent Posts