SlideShare a Scribd company logo
#include <stdio.h>
/*
int main() {
int i,j,n;
n =3;
for(i=0;i<n;i++)
{
for(j=0;j<n;j++)
{
if(j<=i)
{
printf("%d",n);
}
}
printf("n");
}
}/*/
/*
int main (){
int num [4];
printf (" valor posicion 0: n");
scanf (" %d ", &num[4]);
printf (" valor posicion 1: n");
scanf (" %d ", &num[1]);
printf (" valor posicion 2: n ");
scanf (" %d ", &num[2]);
printf (" valor posicion 3: n");
scanf (" %d ", &num[3]);
printf (" **VALORES: ** n");
printf (" 1- %d n ", num[4]);
printf (" 2- %d n ", num[1]);
printf (" 3- %d n ", num[2]);
printf (" 4- %d n ", num[3]);
}*/
/*
int main (){
int num [5],p;
for (p=0;p<5;p++){
printf ("valorposicion %d ", p);
scanf ("%d", &num[p]);
}
printf ("%d",p);
}
*/
int main (){
int num, n;
printf (" Dame el valor de *n*: ");
scanf ("%d", &num);
for (n=0;n<num;n++){
printf ("%d", n++);
}
}

More Related Content

PDF
Linear search
PPTX
PPTX
Structure
PDF
C언어 스터디 강의자료 - 1차시
PDF
Insertion sort
PPTX
Computer programing w
Linear search
Structure
C언어 스터디 강의자료 - 1차시
Insertion sort
Computer programing w

What's hot (17)

DOCX
One dimensional operation of Array in C- language
PPTX
Examples sandhiya class'
TXT
Fred
PDF
10 3 다중 배열
PDF
10 2 배열 응용
PDF
Bcsl 033 data and file structures lab s2-1
PDF
Bcsl 033 data and file structures lab s3-1
PDF
Program in ‘C’ language to implement linear search using pointers
PDF
Bcsl 033 data and file structures lab s3-2
DOCX
Array imp of list
PPTX
C & Python Introduction
PPTX
Array menu
PPTX
งานนำเสนอ1
PDF
Bcsl 033 data and file structures lab s2-3
PDF
Bcsl 033 data and file structures lab s4-2
PDF
Bcsl 033 data and file structures lab s3-3
One dimensional operation of Array in C- language
Examples sandhiya class'
Fred
10 3 다중 배열
10 2 배열 응용
Bcsl 033 data and file structures lab s2-1
Bcsl 033 data and file structures lab s3-1
Program in ‘C’ language to implement linear search using pointers
Bcsl 033 data and file structures lab s3-2
Array imp of list
C & Python Introduction
Array menu
งานนำเสนอ1
Bcsl 033 data and file structures lab s2-3
Bcsl 033 data and file structures lab s4-2
Bcsl 033 data and file structures lab s3-3
Ad

Similar to (Meta 5) ejemplo vectores 2 dev c++ (20)

PDF
Data Structure using C
PDF
Cpd lecture im 207
DOCX
DOC
C basics
PDF
Array Programs.pdf
PPT
C questions
PPTX
C programming BY Mazedur
DOCX
cpract.docx
DOCX
C lab manaual
PPTX
C Programming Language Part 8
DOC
Basic c programs updated on 31.8.2020
DOC
Sorting programs
DOCX
SaraPIC
DOCX
ADA FILE
PDF
The solution manual of c by robin
PDF
C lab programs
PDF
C lab programs
PDF
C Prog - Pointers
Data Structure using C
Cpd lecture im 207
C basics
Array Programs.pdf
C questions
C programming BY Mazedur
cpract.docx
C lab manaual
C Programming Language Part 8
Basic c programs updated on 31.8.2020
Sorting programs
SaraPIC
ADA FILE
The solution manual of c by robin
C lab programs
C lab programs
C Prog - Pointers
Ad

More from Eli Diaz (20)

DOCX
(Meta2.2) ejercicio de variables resuelto dev c++
DOCX
(Meta1.2) problemas de algoritmos, diagramas de flujo y pseudocodigos
DOCX
(Meta2.1) ensayo¨ la programación en la vida diaria y mi área profesional¨
DOCX
(Meta 5.1)función sin parámetros que no retorna valor dev c++
DOCX
(Meta 5)temperatura 3 dev c++
DOCX
(Meta 5)temperatura 2 dev c++
DOCX
(Meta 5.1) base de datos de alumnos dev c++
DOCX
(Meta 5) ejemplo vectores dev c++
DOCX
(Meta 5)temperatura dev c++
DOCX
(Meta 5.1)ventas totales. mayores e inferiores dev c++
DOCX
(Meta 4.2) semestre,numero de materias y cantidad a pagar de un alumno dev c++
DOCX
(Meta 4.2) fiesta de 15 años dev c++
DOCX
(Meta 4.1)mostrar el cuadrado y el residuo de un numero dev c++
DOCX
(Meta 4.1)identificador de numero par e impar dev c++
DOCX
(Meta 4.1)conversosr pesos a dolares y dolares a pesos dev c++
DOCX
(Meta 4.2) fiesta de 15 años 2 dev c++
DOCX
(Meta 4) ejemplo lectura de datos, dato mayor de 3 datos dev c++
DOCX
(Meta 4) ejemplo laboratorios dev c++
DOCX
(Meta 4) ejemplo cursos dev c++
DOCX
(Meta 4) ejemplo asesorias dev c++
(Meta2.2) ejercicio de variables resuelto dev c++
(Meta1.2) problemas de algoritmos, diagramas de flujo y pseudocodigos
(Meta2.1) ensayo¨ la programación en la vida diaria y mi área profesional¨
(Meta 5.1)función sin parámetros que no retorna valor dev c++
(Meta 5)temperatura 3 dev c++
(Meta 5)temperatura 2 dev c++
(Meta 5.1) base de datos de alumnos dev c++
(Meta 5) ejemplo vectores dev c++
(Meta 5)temperatura dev c++
(Meta 5.1)ventas totales. mayores e inferiores dev c++
(Meta 4.2) semestre,numero de materias y cantidad a pagar de un alumno dev c++
(Meta 4.2) fiesta de 15 años dev c++
(Meta 4.1)mostrar el cuadrado y el residuo de un numero dev c++
(Meta 4.1)identificador de numero par e impar dev c++
(Meta 4.1)conversosr pesos a dolares y dolares a pesos dev c++
(Meta 4.2) fiesta de 15 años 2 dev c++
(Meta 4) ejemplo lectura de datos, dato mayor de 3 datos dev c++
(Meta 4) ejemplo laboratorios dev c++
(Meta 4) ejemplo cursos dev c++
(Meta 4) ejemplo asesorias dev c++

Recently uploaded (20)

PDF
Enhancing Cyber Defense Against Zero-Day Attacks using Ensemble Neural Networks
PPT
Introduction, IoT Design Methodology, Case Study on IoT System for Weather Mo...
PPTX
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
PDF
86236642-Electric-Loco-Shed.pdf jfkduklg
PPTX
Artificial Intelligence
PDF
Analyzing Impact of Pakistan Economic Corridor on Import and Export in Pakist...
PPTX
6ME3A-Unit-II-Sensors and Actuators_Handouts.pptx
PPT
introduction to datamining and warehousing
PPTX
Current and future trends in Computer Vision.pptx
PDF
PPT on Performance Review to get promotions
PPTX
Fundamentals of safety and accident prevention -final (1).pptx
PDF
COURSE DESCRIPTOR OF SURVEYING R24 SYLLABUS
PDF
737-MAX_SRG.pdf student reference guides
PDF
Integrating Fractal Dimension and Time Series Analysis for Optimized Hyperspe...
PDF
R24 SURVEYING LAB MANUAL for civil enggi
PDF
EXPLORING LEARNING ENGAGEMENT FACTORS INFLUENCING BEHAVIORAL, COGNITIVE, AND ...
PDF
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
PDF
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
PDF
BIO-INSPIRED HORMONAL MODULATION AND ADAPTIVE ORCHESTRATION IN S-AI-GPT
PPTX
Fundamentals of Mechanical Engineering.pptx
Enhancing Cyber Defense Against Zero-Day Attacks using Ensemble Neural Networks
Introduction, IoT Design Methodology, Case Study on IoT System for Weather Mo...
MET 305 2019 SCHEME MODULE 2 COMPLETE.pptx
86236642-Electric-Loco-Shed.pdf jfkduklg
Artificial Intelligence
Analyzing Impact of Pakistan Economic Corridor on Import and Export in Pakist...
6ME3A-Unit-II-Sensors and Actuators_Handouts.pptx
introduction to datamining and warehousing
Current and future trends in Computer Vision.pptx
PPT on Performance Review to get promotions
Fundamentals of safety and accident prevention -final (1).pptx
COURSE DESCRIPTOR OF SURVEYING R24 SYLLABUS
737-MAX_SRG.pdf student reference guides
Integrating Fractal Dimension and Time Series Analysis for Optimized Hyperspe...
R24 SURVEYING LAB MANUAL for civil enggi
EXPLORING LEARNING ENGAGEMENT FACTORS INFLUENCING BEHAVIORAL, COGNITIVE, AND ...
keyrequirementskkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkk
The CXO Playbook 2025 – Future-Ready Strategies for C-Suite Leaders Cerebrai...
BIO-INSPIRED HORMONAL MODULATION AND ADAPTIVE ORCHESTRATION IN S-AI-GPT
Fundamentals of Mechanical Engineering.pptx

(Meta 5) ejemplo vectores 2 dev c++

  • 1. #include <stdio.h> /* int main() { int i,j,n; n =3; for(i=0;i<n;i++) { for(j=0;j<n;j++) { if(j<=i) { printf("%d",n); } } printf("n"); } }/*/ /* int main (){ int num [4]; printf (" valor posicion 0: n"); scanf (" %d ", &num[4]); printf (" valor posicion 1: n"); scanf (" %d ", &num[1]); printf (" valor posicion 2: n ");
  • 2. scanf (" %d ", &num[2]); printf (" valor posicion 3: n"); scanf (" %d ", &num[3]); printf (" **VALORES: ** n"); printf (" 1- %d n ", num[4]); printf (" 2- %d n ", num[1]); printf (" 3- %d n ", num[2]); printf (" 4- %d n ", num[3]); }*/ /* int main (){ int num [5],p; for (p=0;p<5;p++){ printf ("valorposicion %d ", p); scanf ("%d", &num[p]); } printf ("%d",p); } */ int main (){ int num, n;
  • 3. printf (" Dame el valor de *n*: "); scanf ("%d", &num); for (n=0;n<num;n++){ printf ("%d", n++); } }