This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| khjkhjkkjh |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * Get a diff between two dates | |
| * @param date1 the oldest date | |
| * @param date2 the newest date | |
| * @param timeUnit the unit in which you want the diff, TimeUnit is java.util.concurrent.TimeUnit, a standard Java enum going from nanos to days. | |
| * @return the diff value, in the provided unit | |
| */ | |
| public static long getDateDiff(Date date1, Date date2, TimeUnit timeUnit) { | |
| long diffInMillies = date2.getTime() - date1.getTime(); | |
| return timeUnit.convert(diffInMillies,TimeUnit.MILLISECONDS); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| private UtilConnectionDialogValid utilConnectionValid; | |
| public void main(){ | |
| this.utilConnectionValid= new UtilConnectionDialogValid(this, ConstServices.BASE_URL,R.string.connection_no_server,R.string.connection_no_found); | |
| } | |
| public void daoMethod() | |
| { | |
| if(!this.utilConnectionValid.isConnected()) | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| buildscript { | |
| repositories { | |
| mavenCentral() | |
| maven { | |
| url 'https://oss.sonatype.org/content/repositories/snapshots/' | |
| } | |
| } | |
| dependencies { | |
| classpath 'com.android.tools.build:gradle:0.9.+' | |
| classpath 'com.squareup.gradle:gradle-android-test-plugin:0.9.1-SNAPSHOT' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Copyright: Benjamin Weiss (keyboardsurfer) https://github.com/keyboardsurfer | |
| # Under CC-BY-SA V3.0 (https://creativecommons.org/licenses/by-sa/3.0/legalcode) | |
| # built application files | |
| *.apk | |
| *.ap_ | |
| *.jar | |
| !gradle/wrapper/gradle-wrapper.jar | |
| # lint folder |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @Override | |
| public void onCreate(Bundle savedInstanceState) { | |
| super.onCreate(savedInstanceState); | |
| setContentView(R.layout.activity_comments); | |
| String htmlComments = getHtmlComment("yourId", "yourShortName"); | |
| webDisqus = (WebView) findViewById(R.id.disqus); | |
| // set up disqus | |
| WebSettings webSettings2 = webDisqus.getSettings(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import android.app.Activity; | |
| import android.content.Context; | |
| import android.graphics.Typeface; | |
| import android.support.v4.app.FragmentActivity; | |
| import android.view.View; | |
| import android.view.ViewGroup; | |
| import android.widget.EditText; | |
| import android.widget.TextView; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| TabHost host = (TabHost)findViewById(R.id.tabHost); | |
| host.setup(); | |
| //Tab 1 | |
| TabHost.TabSpec spec = host.newTabSpec("Tab One"); | |
| spec.setContent(R.id.tab1); | |
| spec.setIndicator("Tab One"); | |
| host.addTab(spec); | |
| //Tab 2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # PRIMERA SOLUCION DEL PROBLEMA | |
| # Python code to demonstrate math.factorial() | |
| """ | |
| para que no quede una array super largo | |
| convendria una estructura de dictionario | |
| para darles mas peso como un grafo con pesos | |
| asi el array queda fijo y solo queda multiplicar los pesos segun como | |
| valla avanzando | |
| """ | |
| def getLetterIndices(indice,source,letter): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| Excercise : https://developer.android.com/codelabs/basic-android-kotlin-compose-function-types-and-lambda?hl=es-419&continue=https%3A%2F%2Fdeveloper.android.com%2Fcourses%2Fpathways%2Fandroid-basics-compose-unit-2-pathway-1%3Fhl%3Des-419%23codelab-https%3A%2F%2Fdeveloper.android.com%2Fcodelabs%2Fbasic-android-kotlin-compose-function-types-and-lambda#0 | |
| */ | |
| fun main() { | |
| val trickFunction = ::trick | |
| trickFunction() | |
| trickAsVariable() | |
| trickWhitType() | |
| trickWhitParam("Javier Solis") |
OlderNewer