My favorites
▼
|
Sign in
lineadecodigo
Web Code Samples in spanish
Project Home
Downloads
Wiki
Issues
Source
Checkout
Browse
Changes
Source path:
svn
/
trunk
/
lineadecodigo_java
/
src
/
com
/
lineadecodigo
/
java
/
math
/
PotenciasDelDosConBits.java
r478
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
package com.lineadecodigo.java.math;
/**
* @file PotenciasDelDosConBits.java
* @version 1.0
* @author Linea de Codigo (http://lineadecodigo.com)
* @date 17/enero/2009
* @url http://lineadecodigo.com/2009/01/27/potencias-del-dos-con-desplazamiento-de-bits/
* @description Listado de potencias del 2 mediante el desplazamiento de bits
*/
public class PotenciasDelDosConBits {
public static void main(String[] args) {
int iNumeroPotencias = 10;
System.out.println("Potencias del dos");
for (int x=0;x<=iNumeroPotencias;x++)
System.out.println("2 elevado a " + x + " igual a " + (1 << x));
}
}
Show details
Hide details
Change log
r93
by vcuervo on Jan 26, 2009
Diff
Potencias del 2 con desplazamiento de bits
Go to:
...math/PotenciasDelDosConBits.java
Project members,
sign in
to write a code review
Older revisions
All revisions of this file
File info
Size: 656 bytes, 26 lines
View raw file
Powered by
Google Project Hosting