IntelliJ doesn't play well with Maven if directories don't use the correct capitalization.
<resource>
<directory>${basedir}/src/java</directory>
<includes>
<include>*.xml</include>
</includes>
</resource>
package org.dnorton.java8.example; | |
import java.util.ArrayList; | |
import java.util.Arrays; | |
import java.util.List; | |
/** | |
* Created with IntelliJ IDEA. | |
*/ | |
public class LambdaTest { |
Stream<String> sortedWords = Stream.of("The quick brown dog jumped".split("[\\P{L}]+")).sorted(); | |
sortedWords.forEach(System.out::println); |
files = [f for f in os.listdir('.') if ".sql" in f or ".pkg" in f] |
IntelliJ doesn't play well with Maven if directories don't use the correct capitalization.
<resource>
<directory>${basedir}/src/java</directory>
<includes>
<include>*.xml</include>
</includes>
</resource>
>>> import os | |
>>> import fnmatch | |
>>> | |
>>> for root, dirnames, filenames in os.walk('dir1'): | |
... for filename in fnmatch.filter(filenames, '*.sh'): | |
... print os.path.join(root, filename) |
for i in `find my_dir -name '*.sh'`; do echo $i; sed 's/\r$//' $i $i.unix; cp $i $i.dos; cp $i.unix $i; done |
package com.velogica.metrics; | |
import com.codahale.metrics.*; | |
import com.codahale.metrics.jvm.GarbageCollectorMetricSet; | |
import com.codahale.metrics.jvm.MemoryUsageGaugeSet; | |
import com.codahale.metrics.jvm.ThreadStatesGaugeSet; | |
import org.junit.Test; | |
import rx.Observable; | |
import rx.functions.Action1; |
@echo off | |
set DIR_BASE=C:\nonexisting_dir | |
:test_dir | |
if exist %DIR_BASE%\* ( | |
echo %DIR_BASE% is a Directory | |
) else ( | |
echo %DIR_BASE% is Not a Directory | |
set DIR_BASE=C:\existing_dir |
def _determine_version(artifact): | |
def determine_version(artifact): | |
base_path, symlink_name = os.path.split(artifact) | |
base_name = symlink_name.split('-')[0] | |
version = None | |
version_map = {} | |
version_list = [] | |
list = os.listdir(base_path) |
package main | |
/** | |
Implement Pic. It should return a slice of length dy, each element of which is a slice of dx 8-bit unsigned integers. | |
When you run the program, it will display your picture, interpreting the integers as grayscale (well, bluescale) values. | |
The choice of image is up to you. Interesting functions include x^y, (x+y)/2, and x*y. | |
(You need to use a loop to allocate each []uint8 inside the [][]uint8.) |