精华内容
下载资源
问答
  • Whose 和 Who 基本用法练习题 一选择题 ( )01.Who is your teacher? A. Hes Robert. B. Ada is C.Its Lucys ( )02.Whose is it? A. He s Robert. B. Ada is C.It s Lucys ( )03.Who is he? A. Hes Robert. B. Ada ...
  • Whose-和-Who基本用法习题 精品文档 精品文档 收集于网络如有侵权请联系管理员删除 收集于网络如有侵权请联系管理员删除 精品文档 收集于网络如有侵权请联系管理员删除 Whose和Who基本用法练习题 一选择题 ( )01....
  • Who s e - 和 - Who 基 本 用 法 习 题 精品文档 Whose 和 Who 基本用法练习题 一选择题 ( )01.Who is your teacher? A. Hes Robert. B. Ada is C.Its Lucy s ( )02.Whose is it? A. Hes Robert. B. Ada is C.Its ...
  • TouchDelegate的用法

    千次阅读 2012-06-27 15:58:17
    下面是TouchDelegate官方描述 Helper class to handle situations where you want a view to have a larger touch area than its actual view ... The view whose touch area is changed is called the delegate

    下面是TouchDelegate的官方描述

    Helper class to handle situations where you want a view to have a larger touch area than its actual view bounds. The view whose touch area is changed is called the delegate view. This class should be used by an ancestor of the delegate. To use a TouchDelegate, first create an instance that specifies the bounds that should be mapped to the delegate and the delegate view itself.

    The ancestor should then forward all of its touch events received in its onTouchEvent(MotionEvent) to onTouchEvent(MotionEvent).

    大概是说处理这样一种情况,使view的点击区域大于他的实际尺寸。被改变的点击区域的view称为delegate view。

    用法:

    1. 这个类要被delegate view的父使用;

    2. 这个父要在onTouchEvent()处理自己的所有触摸事件

    注意:

    点击view的实际尺寸区域,会按照正常的逻辑处理view触摸事件;点击扩展的区域,程序会通过TouchDelegate的onTouchEvent()走到view的处理逻辑,区别是后面这个处理的点击坐标和前面不同,扩展区域的点击坐标是不变的,无论点在扩展区域的任何地方,坐标都是(getWidget() / 2, getHeight() / 2),如果MOVE到扩展区域外,则坐标会是一个不变的负数(-(slot * 2), -(slot * 2))


    TouchDelegate的使用

    View parent = (View)v.getParent();
    parent.post(new Runnable() {
     @Override
    public void run() {
    Rect delegateArea = new Rect();
    ChildView delegate = v;
    delegate.getHitRect(delegateArea);
    delegateArea.bottom += 200;
    TouchDelegate expandedArea = new TouchDelegate(delegateArea,
    delegate);
    if (View.class.isInstance(delegate.getParent())) {
    ((View) delegate.getParent())
    .setTouchDelegate(expandedArea);
    }
    }
    });

    
    parent的处理
    

    @Override
    	public boolean onTouchEvent(MotionEvent event){	
    		return super.onTouchEvent(event);
    	}


    展开全文
  • 连接代词的用法

    2019-07-16 23:00:03
    疑问代词在引起从句时,都称为连接代词,包括who,whom, whose, what, which, whoever, whomever, whichever, whatever,一共九个,即除了whose后不能加“-ever”后缀,其余都行。1、主语从句 It hasn’t been ...

    什么是连接代词?
    疑问代词在引起从句时,都称为连接代词,包括who,whom, whose, what, which, whoever, whomever, whichever, whatever,一共九个,即除了whose后不能加“-ever”后缀,其余都行。
    1、主语从句
    It hasn’t been announced who won the prizes.
    还没宣布谁获奖。
    It is clear enough what she meant. 
    她是什么意思很清楚。
    2、宾语从句
    I don’t care what they think. 
    他们怎么想我不管。
    Ask her which she wants. 
    问她要哪一个。
    I didn't know what he wanted. 
    我不知道他想要什么。
    I gave her what she wanted. 
    我给了她想要的一切。(这里的what表示所…的一切事或东西)
    3、表语从句
    The question is who(m) we should trust.
    问题是我们应当相信谁。
    What I want to know is which road we should take.
    我想知道的是我们应走哪条路。
    4、状语从句
    Wherever you go, whatever you do, I will be right here waiting for you.
    无论你去哪里,无论你做了什么,我都会在这里等你。
    5、不定式(都用作宾语或介词的宾语)
    Tell him what to do. 
    告诉他怎样做。
    Lucy can’t decide which to choose. 
    露西不能决定选哪个好。
    They exchanged views on the question of whom to elect. 
    他们就该选谁的问题交换了意见。

    :其中的 ever 主要用于加强语气,含有“一切”、“任何”、“无论”之义。使用这类词时,注意不要按汉语习惯用错句子结构。
    任何人(谁)先来都可以得到一张票。
    误:Anyone comes first can get a ticket. / Who comes first can get a ticket.
    正:Anyone who comes first can get a ticket./ Whoever comes first can get a ticket.
     

    展开全文
  • zip函数的用法

    千次阅读 2018-06-13 17:11:19
    下面是python3解释: class zip(object) | zip(iter1 [,iter2 [...]]) --&... | Return a zip object whose .__next__() method returns a tuple where | the i-th element comes from the i-th i...

    下面是python3的解释:

    class zip(object)
     |  zip(iter1 [,iter2 [...]]) --> zip object
     |  
     |  Return a zip object whose .__next__() method returns a tuple where
     |  the i-th element comes from the i-th iterable argument.  The .__next__()
     |  method continues until the shortest iterable in the argument sequence
     |  is exhausted and then it raises StopIteration.
     |  
     |  Methods defined here:
     |  
     |  __getattribute__(self, name, /)
     |      Return getattr(self, name).
     |  
     |  __iter__(self, /)
     |      Implement iter(self).
     |  
     |  __new__(*args, **kwargs) from builtins.type
     |      Create and return a new object.  See help(type) for accurate signature.
     |  
     |  __next__(self, /)
     |      Implement next(self).
     |  
     |  __reduce__(...)
     |      Return state information for pickling.

    举例说明:

    l1 = [1,2,3,4,5]
    l2 = [11,22,33,44,55]
    l3 = zip(l1,l2)
    print(l3)
    for i in l3:
        print(i)

    结果如下:

    <zip object at 0x7fb1d1676a48>
    (1, 11)
    (2, 22)
    (3, 33)
    (4, 44)
    (5, 55)

    python2和python3的区别在于,python2是直接返回一个新列表,列表的元素是元组,形如:
    [(1, 11), (2, 22), (3, 33), (4, 44), (5, 55)]
    python3则是返回一个生成器。

    练习

    现有两个列表:

    l1 = [12, 34, 55, 4, 3, 56, 7, 3, 2]
    l2 = [21, 43, 22, 7, 34, 3, 23, 2, 8]

    将两个列表按下标一一对应,求较大值,返回一个新的列表。

    结合列表生成式和zip函数,可以很方便求出结果:

    l3 = [x if x > y else y for x, y in zip(l1, l2)]
    print(l3)

    结果如下:

    [21, 43, 55, 7, 34, 56, 23, 3, 8]
    展开全文
  • java.lang.Math.sqrt()返回作为参数传递给它double类型值平方根。如果参数为NaN或负数,则结果为NaN。...用法:public static double sqrt(double a)Parameter:a:the value whose square root is to be retu...

    java.lang.Math.sqrt()返回作为参数传递给它的double类型值的平方根。如果参数为NaN或负数,则结果为NaN。如果参数为正无穷大,则结果为正无穷大。如果传递的参数为正零或负零,则结果将与参数相同。

    用法:

    public static double sqrt(double a)

    Parameter:

    a:the value whose square root is to be returned.

    Return:

    This method returns the positive square root value of

    the argument passed to it.

    例子1:显示java.lang.Math.sqrt()方法的用法。

    // Java program to demonstrate working

    // of java.lang.Math.sqrt() method

    import java.lang.Math;

    class Gfg {

    // driver code

    public static void main(String args[])

    {

    double a = 30;

    System.out.println(Math.sqrt(a));

    a = 45;

    System.out.println(Math.sqrt(a));

    a = 60;

    System.out.println(Math.sqrt(a));

    a = 90;

    System.out.println(Math.sqrt(a));

    }

    }

    输出:

    5.477225575051661

    6.708203932499369

    7.745966692414834

    9.486832980505138

    例子2:当参数为NaN或+ infinity时,显示java.lang.Math.sqrt()方法的用法。

    // Java program to demonstrate working

    // of java.lang.Math.sqrt() method

    import java.lang.Math; // importing java.lang package

    public class GFG {

    public static void main(String[] args)

    {

    double positiveInfinity = Double.POSITIVE_INFINITY;

    double negativeVal = -5;

    double nan = Double.NaN;

    double result;

    // Here argument is negative,

    // output will be NaN

    result = Math.sqrt(negativeVal);

    System.out.println(result);

    // Here argument is positive infinity,

    // output will also positive infinity

    result = Math.sqrt(positiveInfinity);

    System.out.println(result);

    // Here argument is NaN, output will be NaN

    result = Math.sqrt(nan);

    System.out.println(result);

    }

    }

    输出:

    NaN

    Infinity

    NaN

    展开全文
  • python中re模块正则表达式基本用法示例 正则表达式(Regular Expression) 正则表达式是自成一体专业化模块化编程语言,主要实现对字符串一些高级操作,对于支持正则表达式语言都可以用正则表达式处理...
  • Android中Parcelable接口用法   1. Parcelable接口   Interface for classes whose instances can be written to and restored from a Parcel。 Classes implementing the Parcelable interface must...
  • Interface for classes whose instances can be written to and restored from a Parcel。 Classes implementing the Parcelable interface must also have a static field called CREATOR, which i
  • Combines the source Observable with other Observables to create an Observable whose values are calculated from the latest values of each, only when the source emits. 上图说明:从时间轴上看,source ...
  • numpy.iscomplexobj(array):此逻辑函数有助于检查数组复杂...参数:array :[array_like]Input array or object whose elements, we need to test.返回:True, if the input array has a complex element; othe...
  • 一个Native Method就是一个java调用非java代码接口。一个Native Method是这样一个java方法:该方法实现由非java语言实现,比如C。这个特征并非java所特有,很多其它... "A native method is a Java method whose
  • Category用法

    2015-07-18 00:27:50
    今天给大家介绍一下我们常说Category详细用法,首先引用API文档一段话: You use categories to define additional methods of an existing class—even one whose source code is unavailable to you—...
  • 关于:numpy.isneginf(array,y = None):逐个测试是否为负...参数:array:[array_like]Input array or object whose elements, we need to test for infinity.y :[array_like]A boolean array with the same shape ...
  • 关于设置listener监听onClicked事件步骤分析 Steps: 1.tell android you are interested in listening to a button click 2.bring your xml ...3.tell your java button whose responding when it's clicke...
  • python 中 with as的用法

    千次阅读 2013-07-08 21:17:43
    with从Python 2.5就有,需要from __future__ import with_statement。 自python 2.6开始,成为默认关键字。 在What's new in python2.6/3.0...‘ statement is a control-flow structure whose basic structure is:
  • 转自:... 1. Parcelable接口 Interface for classes whose instances can be written to and restored from a Parcel。 Classes implementing the Parcelable interface...
  • 名词性从句引导词基本用法

    千次阅读 2019-07-09 19:57:12
    连接代词: what, which, who, whom, whose 连接副词: when, where, why, how 连接连词: that (宾语从句或表语从句中"that"有时可以省略);whether,if (均表示“是否”表明从句内容不确定性);as if ,as ...
  • define usage:define定义是用户变量。define X=32pass a char type whose value is 32 to the variable X.Use &X to implement in pl/sql block;define xdisplay the value of user variable x. eg. DEFINE X
  • #if defined()的用法

    千次阅读 2009-06-24 11:56:00
    #if defined()语法The special operator defined is used in #if and #elif expressions to test whether a certain name is defined as a macro. defined name and defined (name) are both expressions whose valu
  • The special operator defined is used in #if and #elif expressions to test whether a certain name is defined as a ... defined name and defined (name) are both expressions whose value is 1 if name is...
  • findwindow(api)具体用法

    千次阅读 2009-04-19 15:06:00
    The FindWindow function retrieves a handle to the top-level window whose class name and window name match the specified strings. This function does not search child windows. This function does not
  • java.lang.Math.sin()返回介於0.0和pi之間角度三角正弦。如果參數為NaN或無窮大,...用法:public static double sin(double a)Parameter:a:the value whose sine is to be returned.返回:此方法返回參數正弦...
  • Interface for classes whose instances can be written to and restored from a Parcel。 Classes implementing the Parcelable interface must also have a static field called CREATOR, which
  • Interface for classes whose instances can be written to and restored from a Parcel。 Classes implementing the Parcelable interface must also have a static field called CREATOR, which is
  • 1. numpy.moveaxis(a, source, destination)[source]Move axes of an array to new positions.Other axes remain in their original order.New in version 1.11.0.Parameters:a : np.ndarrayThe array whose axes...
  • Interface for classes whose instances can be written to and restored from a Parcel。 Classes implementing the Parcelable interface must also have a static field called CREATOR, which i...
  • sort用法: 头文件:#include using namespace std;1.默认sort函数是按升序排。对应于1)sort(a,a+n); //两个参数分别为待排序数组首地址和尾地址2.可以自己写一个cmp函数,按特定意图进行排序。对应于2)例如...

空空如也

空空如也

1 2 3
收藏数 58
精华内容 23
关键字:

whose的用法